diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2010-03-05 14:34:03 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2010-03-05 14:34:03 (GMT) |
commit | b501910778714de837dc4367698256e996737e9b (patch) | |
tree | f2dc6d4861ea238a538f41c4306249dad1ac3ea5 /generic/tclFileName.c | |
parent | f7a64b3a111891d5f7f79ce94bbb37abedd30176 (diff) | |
download | tcl-b501910778714de837dc4367698256e996737e9b.zip tcl-b501910778714de837dc4367698256e996737e9b.tar.gz tcl-b501910778714de837dc4367698256e996737e9b.tar.bz2 |
Code Audit results:
* use do { ... } while (0) in macros
* avoid shadowing one local variable with another
* use clearer 'foo.bar++;' instead of '++foo.bar;' where result not
required (i.e., semantically equivalent)
* follow Engineering Manual rules on spacing and declarations
Diffstat (limited to 'generic/tclFileName.c')
-rw-r--r-- | generic/tclFileName.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/generic/tclFileName.c b/generic/tclFileName.c index 8e67238..28c0ab8 100644 --- a/generic/tclFileName.c +++ b/generic/tclFileName.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclFileName.c,v 1.101 2010/02/24 10:45:04 dkf Exp $ + * RCS: @(#) $Id: tclFileName.c,v 1.102 2010/03/05 14:34:04 dkf Exp $ */ #include "tclInt.h" @@ -421,7 +421,7 @@ TclpGetNativePathType( && (path[1] == '/') && isdigit(UCHAR(path[2]))) { path += 3; while (isdigit(UCHAR(*path))) { - ++path; + path++; } } #endif @@ -647,11 +647,12 @@ SplitUnixPath( /* * Check for QNX //<node id> prefix */ + if ((path[0] == '/') && (path[1] == '/') && isdigit(UCHAR(path[2]))) { /* INTL: digit */ path += 3; while (isdigit(UCHAR(*path))) { /* INTL: digit */ - ++path; + path++; } } #endif @@ -1823,7 +1824,7 @@ TclGlob( if (tail[0] == '/') { tail++; } else { - tail+=2; + tail += 2; } Tcl_IncrRefCount(pathPrefix); break; |