* net.cc (get_95_ifconf): Use strcasematch instead of strcasecmp.

* syscalls.cc (_unlink): Ditto.
        (_rename): Ditto.
This commit is contained in:
Corinna Vinschen 2001-03-17 19:53:52 +00:00
parent 75c12e1f7a
commit 8eb72e632c
3 changed files with 9 additions and 3 deletions

View File

@ -1,3 +1,9 @@
Sat Mar 17 20:46:00 2001 Corinna Vinschen <corinna@vinschen.de>
* net.cc (get_95_ifconf): Use strcasematch instead of strcasecmp.
* syscalls.cc (_unlink): Ditto.
(_rename): Ditto.
Sat Mar 17 12:43:15 2001 Christopher Faylor <cgf@cygnus.com>
* path.cc (suffix_scan::next): Avoid searching for foo.lnk twice when

View File

@ -1519,7 +1519,7 @@ get_95_ifconf (struct ifconf *ifc, int what)
if (RegQueryValueEx (subkey, "AdapterName", 0,
NULL, (unsigned char *) adapter,
(size = sizeof adapter, &size)) == ERROR_SUCCESS
&& !strcasecmp (adapter, "MS$PPP"))
&& strcasematch (adapter, "MS$PPP"))
{
++*ppp;
strcpy (ifr->ifr_name, "ppp");

View File

@ -98,7 +98,7 @@ _unlink (const char *ourname)
if (atts != 0xffffffff && atts & FILE_ATTRIBUTE_READONLY)
{
int len = strlen (win32_name.get_win32 ());
if (len > 4 && !strcasecmp (win32_name.get_win32 () + len - 4, ".lnk"))
if (len > 4 && strcasematch (win32_name.get_win32 () + len - 4, ".lnk"))
SetFileAttributes (win32_name.get_win32 (),
win32_name.file_attributes () & ~FILE_ATTRIBUTE_READONLY);
}
@ -1278,7 +1278,7 @@ _rename (const char *oldpath, const char *newpath)
if (real_old.issymlink () && !real_new.error)
{
int len_old = strlen (real_old.get_win32 ());
if (!strcasecmp (real_old.get_win32 () + len_old - 4, ".lnk"))
if (strcasematch (real_old.get_win32 () + len_old - 4, ".lnk"))
{
strcpy (new_lnk_buf, newpath);
strcat (new_lnk_buf, ".lnk");