From: cherierm Date: Wed, 25 Jun 2008 17:49:16 +0000 (+0000) Subject: Make sure that we use Cat.exe on Windows instead cat.exe (mingw32). X-Git-Tag: v3.3~276 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/9d844bfb224bc31ba7f9a338db4f21cca18673d5?ds=sidebyside Make sure that we use Cat.exe on Windows instead cat.exe (mingw32). git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@5826 48e7efb5-ca39-0410-a469-dd3cf9ba447f --- diff --git a/tools/tesh2/src/fstream.c b/tools/tesh2/src/fstream.c index 60a70ac485..f244865eb4 100644 --- a/tools/tesh2/src/fstream.c +++ b/tools/tesh2/src/fstream.c @@ -31,7 +31,7 @@ #ifdef WIN32 static int -is_w32_cmd(const char* cmd, char** path) +is_w32_cmd(char* cmd, char** path) { size_t i = 0; struct stat stat_buff = {0}; @@ -51,6 +51,9 @@ is_w32_cmd(const char* cmd, char** path) { for (i = 0; path[i] != NULL; i++) { + /* use Cat.exe on Windows */ + if(!strcmp(cmd, "cat")) + cmd[0] = 'C'; sprintf(buff,"%s\\%s",path[i], cmd);