Skip to content

Commit

Permalink
Update main.c
Browse files Browse the repository at this point in the history
Replace "_splitpath"
  • Loading branch information
fxzxmic authored Dec 29, 2020
1 parent 1d0d938 commit a18a754
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,11 @@

int main(int argc, char *argv[]) {
//Get program path information
char path_buffer[_MAX_PATH];
char drive[_MAX_DRIVE];
char dir[_MAX_DIR];
char fname[_MAX_FNAME];
char ext[_MAX_EXT];
_splitpath(argv[0], drive, dir, fname, ext);
_splitpath_s(argv[0], drive, dir, fname, ext);
//Splice command
char ch[100] = "bash.exe -c \"";
strcat_s(ch, sizeof(ch), fname);
Expand Down

0 comments on commit a18a754

Please sign in to comment.