ANSI-fied sources, converted to four-space indentation.

This commit is contained in:
Fred Drake 2000-07-08 06:16:37 +00:00
parent da940d8f8d
commit edabdc1e9e
1 changed files with 329 additions and 338 deletions

View File

@ -139,8 +139,7 @@ static char *module_search_path = NULL;
static char lib_python[20]; /* Dynamically set to "lib/python" VERSION */
static void
reduce(dir)
char *dir;
reduce(char *dir)
{
size_t i = strlen(dir);
while (i > 0 && dir[i] != SEP)
@ -158,8 +157,7 @@ reduce(dir)
#endif
static int
isfile(filename) /* Is file, not directory */
char *filename;
isfile(char *filename) /* Is file, not directory */
{
struct stat buf;
if (stat(filename, &buf) != 0)
@ -171,8 +169,7 @@ isfile(filename) /* Is file, not directory */
static int
ismodule(filename) /* Is module -- check for .pyc/.pyo too */
char *filename;
ismodule(char *filename) /* Is module -- check for .pyc/.pyo too */
{
if (isfile(filename))
return 1;
@ -188,8 +185,7 @@ ismodule(filename) /* Is module -- check for .pyc/.pyo too */
static int
isxfile(filename) /* Is executable file */
char *filename;
isxfile(char *filename) /* Is executable file */
{
struct stat buf;
if (stat(filename, &buf) != 0)
@ -203,8 +199,7 @@ isxfile(filename) /* Is executable file */
static int
isdir(filename) /* Is directory */
char *filename;
isdir(char *filename) /* Is directory */
{
struct stat buf;
if (stat(filename, &buf) != 0)
@ -216,9 +211,7 @@ isdir(filename) /* Is directory */
static void
joinpath(buffer, stuff)
char *buffer;
char *stuff;
joinpath(char *buffer, char *stuff)
{
size_t n, k;
if (stuff[0] == SEP)
@ -237,9 +230,7 @@ joinpath(buffer, stuff)
static int
search_for_prefix(argv0_path, home)
char *argv0_path;
char *home;
search_for_prefix(char *argv0_path, char *home)
{
size_t n;
char *vpath;
@ -306,9 +297,7 @@ search_for_prefix(argv0_path, home)
static int
search_for_exec_prefix(argv0_path, home)
char *argv0_path;
char *home;
search_for_exec_prefix(char *argv0_path, char *home)
{
size_t n;
@ -389,8 +378,10 @@ calculate_path()
/* Frameworks have support for versioning */
strcpy(lib_python, "lib");
} else {
/* If we're not in a framework, fall back to the old way (even though NSNameOfModule() probably does the same thing.) */
}
else {
/* If we're not in a framework, fall back to the old way
(even though NSNameOfModule() probably does the same thing.) */
#endif
/* Initialize this dynamically for K&R C */