Permalink
Browse files

Renamed tmpdir() functions

  • Loading branch information...
megastep committed Nov 10, 2004
1 parent 90221ae commit 140b99fe4f3405e3fa02d9d35d2e3be6cd1d36a4
Showing with 10 additions and 10 deletions.
  1. +1 −1 copy.c
  2. +2 −2 file.c
  3. +5 −5 file.h
  4. +2 −2 main.c
View
2 copy.c
@@ -613,7 +613,7 @@ static char* write_temp_script(const char* name, char* name_out,
name_out[PATH_MAX-1] = '\0';
name_out[PATH_MAX-2] = '\0';
strncpy(name_out, tmpdir(), PATH_MAX-2);
strncpy(name_out, dir_mktmp(), PATH_MAX-2);
name_out[strlen(name_out)] = '/';
strncpy(name_out+strlen(name_out), name, PATH_MAX-strlen(name_out)-1);
View
4 file.c
@@ -788,7 +788,7 @@ static void dobz2init()
static char tmpdirname[PATH_MAX] = "\0";
const char* tmpdir()
const char* dir_mktmp(void)
{
unsigned count;
@@ -810,7 +810,7 @@ const char* tmpdir()
return NULL;
}
int cleantmpdir()
int dir_cleantmp(void)
{
DIR* dir;
struct dirent *entry;
View
10 file.h
@@ -1,4 +1,4 @@
/* $Id: file.h,v 1.24 2004-11-10 22:23:07 megastep Exp $ */
/* $Id: file.h,v 1.25 2004-11-10 22:26:08 megastep Exp $ */
#ifndef __LOKI_FILE_H__
#define __LOKI_FILE_H__
@@ -56,11 +56,11 @@ extern void file_create_hierarchy(install_info *info, const char *path);
extern void dir_create_hierarchy(install_info *info, const char *path, int mode);
extern int dir_is_accessible(const char *path);
/** create a temporary directory and return it's name. Failure to create the
/** Create a temporary directory and return it's name. Failure to create the
* directory will abort the program. It is only allowed to created inodes that
* can be removed with unlink() in that directory */
extern const char* tmpdir();
extern const char *dir_mktmp(void);
/** clean all files in the temporary directory and remove it */
extern int cleantmpdir();
/** Clean all files in the temporary directory and remove it */
extern int dir_cleantmp(void);
#endif
View
4 main.c
@@ -1,4 +1,4 @@
/* $Id: main.c,v 1.75 2004-11-10 22:23:07 megastep Exp $ */
/* $Id: main.c,v 1.76 2004-11-10 22:26:08 megastep Exp $ */
/*
Modifications by Borland/Inprise Corp.:
@@ -75,7 +75,7 @@ void exit_setup(int ret)
FreePlugins();
free_corrupt_files();
unmount_filesystems();
cleantmpdir();
dir_cleantmp();
log_exit();
exit(ret);
}

0 comments on commit 140b99f

Please sign in to comment.