diff options
author | Ron Yorston <rmy@pobox.com> | 2020-08-28 11:08:24 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2020-08-28 11:08:24 +0100 |
commit | adf41838bb4d33efc8069f9590f8e7ccc3978295 (patch) | |
tree | d2763525a85bc220a5cfce6491710d67521e1926 /win32 | |
parent | 5f696450596f34c80edb1bf866a876fcc8692334 (diff) | |
download | busybox-w32-adf41838bb4d33efc8069f9590f8e7ccc3978295.tar.gz busybox-w32-adf41838bb4d33efc8069f9590f8e7ccc3978295.tar.bz2 busybox-w32-adf41838bb4d33efc8069f9590f8e7ccc3978295.zip |
ash, ls: improve support for 'c:path'
Revert commit 249f68e3c (win32: append '/' to bare drive name in
opendir).
Instead add better handling for paths of the form 'c:path' to ls
and expmeta() in ash.
Adds 64 bytes.
Diffstat (limited to 'win32')
-rw-r--r-- | win32/mingw.c | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/win32/mingw.c b/win32/mingw.c index 051dc3c0d..16e103b54 100644 --- a/win32/mingw.c +++ b/win32/mingw.c | |||
@@ -1528,21 +1528,6 @@ size_t FAST_FUNC remove_cr(char *p, size_t len) | |||
1528 | return j; | 1528 | return j; |
1529 | } | 1529 | } |
1530 | 1530 | ||
1531 | #undef opendir | ||
1532 | DIR *mingw_opendir(const char *path) | ||
1533 | { | ||
1534 | char name[4]; | ||
1535 | |||
1536 | if (isalpha(path[0]) && path[1] == ':' && path[2] == '\0') { | ||
1537 | strcpy(name, path); | ||
1538 | name[2] = '/'; | ||
1539 | name[3] = '\0'; | ||
1540 | path = name; | ||
1541 | } | ||
1542 | |||
1543 | return opendir(path); | ||
1544 | } | ||
1545 | |||
1546 | off_t mingw_lseek(int fd, off_t offset, int whence) | 1531 | off_t mingw_lseek(int fd, off_t offset, int whence) |
1547 | { | 1532 | { |
1548 | HANDLE h = (HANDLE)_get_osfhandle(fd); | 1533 | HANDLE h = (HANDLE)_get_osfhandle(fd); |