From 633def3c636ac61802a68fbfd018e7d9130d8d6e Mon Sep 17 00:00:00 2001 From: nobu Date: Wed, 16 Apr 2014 02:46:51 +0000 Subject: [PATCH] dln_find.c: PATH_SEP * dln_find.c (dln_find_exe_r): use PATH_SEP instead of hardcoding separators. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45596 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- dln_find.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/dln_find.c b/dln_find.c index f41ceb051d..56a19818cf 100644 --- a/dln_find.c +++ b/dln_find.c @@ -78,11 +78,12 @@ dln_find_exe_r(const char *fname, const char *path, char *buf, size_t size } if (!path) { -#if defined(_WIN32) - path = "/usr/local/bin;/usr/ucb;/usr/bin;/bin;."; -#else - path = "/usr/local/bin:/usr/ucb:/usr/bin:/bin:."; -#endif + path = + "/usr/local/bin" PATH_SEP + "/usr/ucb" PATH_SEP + "/usr/bin" PATH_SEP + "/bin" PATH_SEP + "."; } buf = dln_find_1(fname, path, buf, size, 1 DLN_FIND_EXTRA_ARG); if (envpath) free(envpath);