[Nut-upsdev] [Patch] upssched broken in version 2.6.4 with command with two arguments

Vladimir Volovich vladimir.volovich at gmail.com
Tue Jul 3 15:37:13 UTC 2012


Hi Oliver,

Thank you. I've rebuilt the nut packages with your patch, and confirmed
that the problem is fixed: I get the proper system shutdown.

Best wishes,
Vladimir

On Tue, Jul 3, 2012 at 6:33 PM, Oliver Schonefeld <
schonefeld at ids-mannheim.de> wrote:

> Hi,
>
> the last commit to upssched.c (Merge Coverity branch, r3555) broke
> upssched with commands that have a second argument.
> If a command with a second argument is used, "enc" in line 697 is not an
> empty buffer and  snprintfcat() just appends some stuff, i.e. the
> following command
>   CANCEL onbatt online
> becomes
>   onlineCANCEL "onbatt" "online"
> and is then sent to the pipe-fd.
>
> The attached patch replaces snprintfcat() with snprintf() and fixes the
> problem.
>
> Best,
>   Oliver
> --
> Oliver Schonefeld
> Institut für Deutsche Sprache, Zentrale Forschung
> R5, 6-13, D-68161 Mannheim
> +49-(0)621-1581-451 | http://www.ids-mannheim.de
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsdev/attachments/20120703/be9a5f79/attachment.html>


More information about the Nut-upsdev mailing list