Check for argc==0 when calling wtokensplit()
commitf516213bf3b5906365e90db731bff310802d9938
authorTobias Stoeckmann <unknown-email>
Sat, 15 Aug 2009 22:16:58 +0000 (16 00:16 +0200)
committerCarlos R. Mafra <crmafra@gmail.com>
Sat, 15 Aug 2009 22:16:58 +0000 (16 00:16 +0200)
tree9f0b7f69376a89f162841e058e5d305f35d09852
parentbbc52564d06aa47b6a0045c7967275a2b4c4f32d
Check for argc==0 when calling wtokensplit()

The WINGs-function wtokensplit does not set argv to NULL if no string has been
split - instead argc is set to 0.

You can only observe this issue if you compile Window Maker without any
optimization:

compile Window Maker with CFLAGS=""
run Window Maker and save a session
change session-file and replace a 'command xyz' line with 'command " "'
restart Window Maker
watch "Fatal error"-message

Retrieved-from: http://paldium.homeunix.org/tobias/wmaker/
Submitted-by: Gilbert Ashley <amigo@ibiblio.org>
src/dock.c
src/session.c