delorie.com/archives/browse.cgi | search |
Message-ID: | <B0FEA00E82A7D1118BFB00A0CC99027821345D@ARGON> |
From: | Michel de Ruiter <Michel AT smr DOT nl> |
To: | "'djgpp-workers AT delorie DOT com'" <djgpp-workers AT delorie DOT com> |
Cc: | "'Laurynas Biveinis'" <lauras AT softhome DOT net> |
Subject: | RE: Second symlink patch |
Date: | Tue, 7 Dec 1999 12:52:05 +0100 |
MIME-Version: | 1.0 |
X-Mailer: | Internet Mail Service (5.5.2650.21) |
Reply-To: | djgpp-workers AT delorie DOT com |
Hi, all Two minor things I spotted in the symlink patches: +static char * find_dir_sep(const char * path) +{ + char * dir_sep = strchr(path, '/'); + if (!dir_sep) + return strchr(path, '\\'); + return dir_sep; +} Why not split c:\djgpp\share/app/file.ext correctly? For example just: return strpbrk(path, "/\\"); +/* It is big enough to hold longest posssible path */ One `s' too many, I guess. Hope this helps. -- Groente, Michel.
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |