Daniel Shahaf wrote: > Bert Huijben wrote on Wed, May 22, 2013 at 10:50:17 +0200: >>> failed_command = apr_pstrcat(pool, failed_command, cmd[i]); >>> failed_command = apr_pstrcat(pool, failed_command, " "); >> >> Note that apr_pstrcat needs a final NULL argument :) >> >> So you could use apr_pstrcat(pool, failed_command, " ", cmd[i], NULL); > > You need to explicitly cast the last NULL: > > apr_pstrcat(pool, failed_command, " ", cmd[i], (void *)NULL); > > (because it's a variadic function so there is no implicit conversion to > a pointer, when NULL is #define'd to be a 0 narrower than the pointer)
For a strcat, the arguments are pointers to 'char', so it looks better to use (char *)NULL. - Julian

