libedi_scm: make sure we always change to valid directory.

This commit is contained in:
Al Poole 2017-10-08 14:44:34 +01:00
parent 7ea3ce5d84
commit 2a9d02fc2f
1 changed files with 2 additions and 2 deletions

View File

@ -27,7 +27,7 @@ _edi_scm_exec(const char *command)
oldpwd = getcwd(NULL, PATH_MAX);
chdir(edi_project_get());
chdir(self->workdir);
code = edi_exe_wait(command);
chdir(oldpwd);
@ -46,7 +46,7 @@ _edi_scm_exec_response(const char *command)
oldpwd = getcwd(NULL, PATH_MAX);
chdir(edi_project_get());
chdir(self->workdir);
response = edi_exe_response(command);
chdir(oldpwd);