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 /shell | |
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 'shell')
-rw-r--r-- | shell/ash.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/shell/ash.c b/shell/ash.c index 1d7d916da..1f57c2d7e 100644 --- a/shell/ash.c +++ b/shell/ash.c | |||
@@ -8293,6 +8293,10 @@ expmeta(exp_t *exp, char *name, unsigned name_len, unsigned expdir_len) | |||
8293 | 8293 | ||
8294 | metaflag = 0; | 8294 | metaflag = 0; |
8295 | start = name; | 8295 | start = name; |
8296 | #if ENABLE_PLATFORM_MINGW32 | ||
8297 | if (expdir_len == 0 && has_dos_drive_prefix(start) && start[2] != '/') | ||
8298 | start += 2; | ||
8299 | #endif | ||
8296 | for (p = name; esc = 0, *p; p += esc + 1) { | 8300 | for (p = name; esc = 0, *p; p += esc + 1) { |
8297 | if (*p == '*' || *p == '?') | 8301 | if (*p == '*' || *p == '?') |
8298 | metaflag = 1; | 8302 | metaflag = 1; |