I also managed to reproduce it using dummy-ups (the simulation driver) and
injecting the error on the same variable:
adding a newline (ie "\n") results in a broken pipe on upsc side.
> i am ready to test svn version.
>
ok, here we go:
1) checkout an svn copy using:
$ svn co svn://svn.debian.org/nut/trunk
2) configure it using (Debian arguments, limited for the current test scope
; should be sufficient):
--prefix=/usr \ --exec-prefix=/ \ --sysconfdir=/etc/nut \ --mandir=/usr/share/man \ --libdir=/lib \ --includedir=/usr/include \ --without-all \ --with-usb \ --enable-static \ --with-statepath=/var/run/nut \ --with-altpidpath=/var/run/nut \ --with-drvpath=/lib/nut \ --with-pidpath=/var/run/nut \ --datadir=/usr/share/nut \ --with-pkgconfig-dir=/usr/lib/pkgconfig \ --with-user=nut --with-group=nut
3) apply the attached patch
$ patch -p0 < /path/to/virus.patch
4) make as usual, ie
$ make
5) stop all previous NUT instances, then launch the new driver and upsd
$ sudo drivers/usbhid-ups -a powercom
$ sudo server/upsd -DDD
6) now issue your "upsc of death"
$ upsc powercom
everything should behave fine.
Remember that it's a "blind patch": I've not validated the above configure
line, nor the patch itself!
2011/4/18 Virus <email address hidden>
> yes, it 100 % reproducible.
>
I also managed to reproduce it using dummy-ups (the simulation driver) and
injecting the error on the same variable:
adding a newline (ie "\n") results in a broken pipe on upsc side.
> i am ready to test svn version.
>
ok, here we go: debian. org/nut/ trunk
1) checkout an svn copy using:
$ svn co svn://svn.
2) configure it using (Debian arguments, limited for the current test scope
-- exec-prefix= / \
-- sysconfdir= /etc/nut \
-- mandir= /usr/share/ man \
-- libdir= /lib \
-- includedir= /usr/include \
-- without- all \
-- with-usb \
-- enable- static \
-- with-statepath= /var/run/ nut \
-- with-altpidpath =/var/run/ nut \
-- with-drvpath= /lib/nut \
-- with-pidpath= /var/run/ nut \
-- datadir= /usr/share/ nut \
-- with-pkgconfig- dir=/usr/ lib/pkgconfig \
-- with-user= nut --with-group=nut
; should be sufficient):
--prefix=/usr \
3) apply the attached patch virus.patch
$ patch -p0 < /path/to/
4) make as usual, ie
$ make
5) stop all previous NUT instances, then launch the new driver and upsd
$ sudo drivers/usbhid-ups -a powercom
$ sudo server/upsd -DDD
6) now issue your "upsc of death"
$ upsc powercom
everything should behave fine.
Remember that it's a "blind patch": I've not validated the above configure
line, nor the patch itself!
cheers, powerquality. eaton.com www.networkupst ools.org/ www.debian. org arnaud. quette. free.fr/
Arnaud
--
Linux / Unix Expert R&D - Eaton - http://
Network UPS Tools (NUT) Project Leader - http://
Debian Developer - http://
Free Software Developer - http://