diff options
author | Christopher Faylor <me@cgf.cx> | 2002-06-06 00:09:55 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2002-06-06 00:09:55 +0000 |
commit | ee964e2f97ca0ca9033b6daf975cada710a46737 (patch) | |
tree | c3cbe756486fff12e467b6f55a8263f7380fccc1 /winsup/cygwin/path.cc | |
parent | 39e65e0113e188e4177077407d337bb3a1ac1853 (diff) | |
download | newlib-ee964e2f97ca0ca9033b6daf975cada710a46737.zip newlib-ee964e2f97ca0ca9033b6daf975cada710a46737.tar.gz newlib-ee964e2f97ca0ca9033b6daf975cada710a46737.tar.bz2 |
* cygwin.din: Eliminate some newlib wrappers.
* path.cc (get_devn): Only consider first 99 potential com devices.
(get_device_number): Ditto.
* times.cc (_times): Eliminate.
(_times): Renamed from times().
Diffstat (limited to 'winsup/cygwin/path.cc')
-rw-r--r-- | winsup/cygwin/path.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc index 25412b2..336df5e 100644 --- a/winsup/cygwin/path.cc +++ b/winsup/cygwin/path.cc @@ -916,7 +916,7 @@ get_devn (const char *name, int &unit) devn = FH_MEM; unit = 4; } - else if (deveqn ("com", 3) && (unit = digits (name + 3)) >= 0) + else if (deveqn ("com", 3) && (unit = digits (name + 3)) >= 0 && unit < 100) devn = FH_SERIAL; else if (deveqn ("ttyS", 4) && (unit = digits (name + 4)) >= 0) { @@ -1070,7 +1070,7 @@ get_device_number (const char *unix_path, const char *w32_path, int &unit) if (p) unix_path = p + 1; if (udeveqn ("com", 3) - && (unit = digits (unix_path + 3)) >= 0) + && (unit = digits (unix_path + 3)) >= 0 && unit < 100) devn = FH_SERIAL; } |