Make this not crash when compiled with -g.

Found by myself, analysis by kurt@, fix by me with input from otto.

``Just get some fix in...'' deraadt
This commit is contained in:
mk
2008-06-16 19:09:48 +00:00
parent 07cd0b1ac5
commit 867652c484
2 changed files with 3 additions and 6 deletions

View File

@@ -100,11 +100,8 @@ yesno : YES { $$ = 1; }
;
main : FONTNAME STRING {
if (conf->DefaultFontName != NULL &&
conf->DefaultFontName != DEFAULTFONTNAME)
free(conf->DefaultFontName);
conf->DefaultFontName = xstrdup($2);
free($2);
free(conf->DefaultFontName);
conf->DefaultFontName = $2;
}
| STICKY yesno {
if ($2 == 0)