diff options
author | Andrew MacIntyre <andymac@bullseye.apana.org.au> | 2003-04-22 03:21:42 (GMT) |
---|---|---|
committer | Andrew MacIntyre <andymac@bullseye.apana.org.au> | 2003-04-22 03:21:42 (GMT) |
commit | 0c83348d5c110a6ca706219019e97d5cefe2fddb (patch) | |
tree | bd4be5331c889044de6470147d476e90b2373171 /PC/os2emx/getpathp.c | |
parent | 699cbb767628888901d1a3c1f0ce20dd3ce1e4f9 (diff) | |
download | cpython-0c83348d5c110a6ca706219019e97d5cefe2fddb.zip cpython-0c83348d5c110a6ca706219019e97d5cefe2fddb.tar.gz cpython-0c83348d5c110a6ca706219019e97d5cefe2fddb.tar.bz2 |
minor cleanups and whitespace normalisation
Diffstat (limited to 'PC/os2emx/getpathp.c')
-rw-r--r-- | PC/os2emx/getpathp.c | 38 |
1 files changed, 20 insertions, 18 deletions
diff --git a/PC/os2emx/getpathp.c b/PC/os2emx/getpathp.c index ab31c65..4a4c893 100644 --- a/PC/os2emx/getpathp.c +++ b/PC/os2emx/getpathp.c @@ -94,9 +94,9 @@ is_sep(char ch) /* determine if "ch" is a separator character */ #endif } -/* assumes 'dir' null terminated in bounds. Never writes - beyond existing terminator. -*/ +/* assumes 'dir' null terminated in bounds. + * Never writes beyond existing terminator. + */ static void reduce(char *dir) { @@ -113,11 +113,12 @@ exists(char *filename) return stat(filename, &buf) == 0; } -/* Assumes 'filename' MAXPATHLEN+1 bytes long - - may extend 'filename' by one character. -*/ +/* Is module (check for .pyc/.pyo too) + * Assumes 'filename' MAXPATHLEN+1 bytes long - + * may extend 'filename' by one character. + */ static int -ismodule(char *filename) /* Is module -- check for .pyc/.pyo too */ +ismodule(char *filename) { if (exists(filename)) return 1; @@ -151,9 +152,9 @@ join(char *buffer, char *stuff) } /* gotlandmark only called by search_for_prefix, which ensures - 'prefix' is null terminated in bounds. join() ensures - 'landmark' can not overflow prefix if too long. -*/ + * 'prefix' is null terminated in bounds. join() ensures + * 'landmark' can not overflow prefix if too long. + */ static int gotlandmark(char *landmark) { @@ -167,7 +168,8 @@ gotlandmark(char *landmark) } /* assumes argv0_path is MAXPATHLEN+1 bytes long, already \0 term'd. - assumption provided by only caller, calculate_path() */ + * assumption provided by only caller, calculate_path() + */ static int search_for_prefix(char *argv0_path, char *landmark) { @@ -283,13 +285,13 @@ calculate_path(void) } /* We need to construct a path from the following parts. - (1) the PYTHONPATH environment variable, if set; - (2) the zip archive file path; - (3) the PYTHONPATH config macro, with the leading "." - of each component replaced with pythonhome, if set; - (4) the directory containing the executable (argv0_path). - The length calculation calculates #3 first. - */ + * (1) the PYTHONPATH environment variable, if set; + * (2) the zip archive file path; + * (3) the PYTHONPATH config macro, with the leading "." + * of each component replaced with pythonhome, if set; + * (4) the directory containing the executable (argv0_path). + * The length calculation calculates #3 first. + */ /* Calculate size of return buffer */ if (pythonhome != NULL) { |