mirror of
https://github.com/paxed/dgamelaunch.git
synced 2025-07-29 16:45:35 +02:00
Fix segfault when no mkdir or chdir defined
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@358 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
This commit is contained in:
parent
d107435cff
commit
f4a322f996
@ -1959,13 +1959,17 @@ main (int argc, char** argv)
|
|||||||
myconfig[userchoice]->bin_args[i] = tmp;
|
myconfig[userchoice]->bin_args[i] = tmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
tmp = strdup(dgl_format_str(userchoice, me, myconfig[userchoice]->mkdir));
|
if (myconfig[userchoice]->mkdir) {
|
||||||
free(myconfig[userchoice]->mkdir);
|
tmp = strdup(dgl_format_str(userchoice, me, myconfig[userchoice]->mkdir));
|
||||||
myconfig[userchoice]->mkdir = tmp;
|
free(myconfig[userchoice]->mkdir);
|
||||||
|
myconfig[userchoice]->mkdir = tmp;
|
||||||
|
}
|
||||||
|
|
||||||
tmp = strdup(dgl_format_str(userchoice, me, myconfig[userchoice]->chdir));
|
if (myconfig[userchoice]->chdir) {
|
||||||
free(myconfig[userchoice]->chdir);
|
tmp = strdup(dgl_format_str(userchoice, me, myconfig[userchoice]->chdir));
|
||||||
myconfig[userchoice]->chdir = tmp;
|
free(myconfig[userchoice]->chdir);
|
||||||
|
myconfig[userchoice]->chdir = tmp;
|
||||||
|
}
|
||||||
|
|
||||||
/* launch program */
|
/* launch program */
|
||||||
ttyrec_main (userchoice, me->username, gen_ttyrec_filename());
|
ttyrec_main (userchoice, me->username, gen_ttyrec_filename());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user