<div dir="ltr"><div class="im" style="font-family:arial,sans-serif;font-size:13px">On Mon, Jun 30, 2014 at 11:55 AM, Thorsten Wißmann <span dir="ltr"><<a href="mailto:edu@thorsten-wissmann.de" target="_blank">edu@thorsten-wissmann.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hi,<br><div><br>On Wed, Jun 25, 2014 at 01:09:44PM +0200, Florian Schmaus wrote:<br>
>          if (print_signal) {<br>> -            // just print as list<br>> -            for (int i = 0; i < hook_argc; i++) {<br>> -                printf("%s%s", i ? "\t" : "", hook_argv[i]);<br>
> +            if (g_print_last_arg_only) {<br>> +                // This assumes that hook_argc is always > 0!<br>> +                printf("%s", hook_argv[hook_argc-1]);<br>> +            } else {<br>
<br></div>Don't assume it, check it :). I've just added a check for it such that<br>"empty" hooks are simply dropped.<br></blockquote><div><br></div></div><div style="font-family:arial,sans-serif;font-size:13px">
I figured you would guarantee it. :) But of course, checking the preconditions is always a</div><div style="font-family:arial,sans-serif;font-size:13px">good idea!</div><div style="font-family:arial,sans-serif;font-size:13px">
<br></div><div style="font-family:arial,sans-serif;font-size:13px">Best,</div><div style="font-family:arial,sans-serif;font-size:13px"> Florian</div><div class="gmail_extra"><br></div></div>