projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
cleanup
[pspp]
/
src
/
data
/
file-name.c
diff --git
a/src/data/file-name.c
b/src/data/file-name.c
index 1c47b4751bd2cff865709fb000e02b20bc47838c..184a79aa4f79ae1b7e1c40de95a414e0922655da 100644
(file)
--- a/
src/data/file-name.c
+++ b/
src/data/file-name.c
@@
-36,7
+36,6
@@
#include "libpspp/version.h"
#include "gl/dirname.h"
#include "libpspp/version.h"
#include "gl/dirname.h"
-#include "gl/dosname.h"
#include "gl/intprops.h"
#include "gl/minmax.h"
#include "gl/relocatable.h"
#include "gl/intprops.h"
#include "gl/minmax.h"
#include "gl/relocatable.h"
@@
-99,9
+98,9
@@
fn_search_path (const char *base_name, char **path)
file = xasprintf ("%s/%s", dir, base_name);
struct stat temp;
file = xasprintf ("%s/%s", dir, base_name);
struct stat temp;
- if ((
(stat (file, &temp) == 0 ) && ( ! S_ISDIR (temp.st_mode)
)))
+ if ((
(stat (file, &temp) == 0) && (! S_ISDIR (temp.st_mode)
)))
return file;
return file;
-
+
free (file);
}
free (file);
}
@@
-116,7
+115,7
@@
fn_exists (const struct file_handle *fh)
{
const char *name = fh_get_file_name (fh);
struct stat temp;
{
const char *name = fh_get_file_name (fh);
struct stat temp;
- if (
stat (name, &temp) != 0
)
+ if (
stat (name, &temp) != 0
)
return false;
return ! S_ISDIR (temp.st_mode);
return false;
return ! S_ISDIR (temp.st_mode);
@@
-199,9
+198,9
@@
fn_open (const struct file_handle *fh, const char *mode)
free (ss);
return fp;
}
free (ss);
return fp;
}
-#else
+#else
return fopen (fn, mode);
return fopen (fn, mode);
-#endif
+#endif
}
/* Counterpart to fn_open that closes file F with name FN; returns 0
}
/* Counterpart to fn_open that closes file F with name FN; returns 0
@@
-236,7
+235,7
@@
default_output_path (void)
{
static char *path = NULL;
{
static char *path = NULL;
- if (
path == NULL)
+ if (path == NULL)
{
/* Windows NT defines HOMEDRIVE and HOMEPATH. But give preference
to HOME, because the user can change HOME. */
{
/* Windows NT defines HOMEDRIVE and HOMEPATH. But give preference
to HOME, because the user can change HOME. */