diff options
author | Fumitoshi UKAI <ukai@debian.or.jp> | 2003-01-10 16:42:14 +0000 |
---|---|---|
committer | Fumitoshi UKAI <ukai@debian.or.jp> | 2003-01-10 16:42:14 +0000 |
commit | 66d04cc1619b037bff177acdffbbe52fbdaaa4b3 (patch) | |
tree | b4c200409e18e49c21b126f02121cef3bc67a85a /etc.c | |
parent | [w3m-dev 03628] Re: Error occured while reset (diff) | |
download | w3m-66d04cc1619b037bff177acdffbbe52fbdaaa4b3.tar.gz w3m-66d04cc1619b037bff177acdffbbe52fbdaaa4b3.zip |
[w3m-dev 03629] delete tmp file
* etc.c (tempfname): always file to delete
* file.c (xface2xpm): no need fileToDelete
(readHeader): ditto
(loadGeneralFile): ditto
(loadHTMLBuffer): ditto
(loadHTMLString): ditto
(loadGopherDir): ditto
(loadImageBuffer): ditto
(doExternal): rewrite
(doFileSave): no need fileToDelete
(uncompress_stream): ditto
* fm.h (CurrentPid): added
* image.c (getImage): cache->touch to delete
* local.c (setLocalCookie): use CurrentPid
(localcgi_post): fileToDelete
* main.c (main): CurrentPid
(pipeBuf): no need fileToDelete
(query_from_followform): CurrentPid
(vmSrc): no need fileToDelete
From: Hironori SAKAMOTO <hsaka@mth.biglobe.ne.jp>
Diffstat (limited to '')
-rw-r--r-- | etc.c | 10 |
1 files changed, 3 insertions, 7 deletions
@@ -1,4 +1,4 @@ -/* $Id: etc.c,v 1.46 2002/12/27 16:09:18 ukai Exp $ */ +/* $Id: etc.c,v 1.47 2003/01/10 16:42:26 ukai Exp $ */ #include "fm.h" #include <pwd.h> #include "myctype.h" @@ -7,11 +7,6 @@ #include "hash.h" #include "terms.h" -#ifdef HAVE_GETCWD /* ??? ukai */ -#include <unistd.h> -#include <sys/param.h> -#endif /* HAVE_GETCWD */ - #include <sys/types.h> #include <time.h> #if defined(HAVE_WAITPID) || defined(HAVE_WAIT3) @@ -1517,7 +1512,8 @@ tmpfname(int type, char *ext) tmpf = Sprintf("%s/w3m%s%d-%d%s", rc_dir, tmpf_base[type], - (int)getpid(), tmpf_seq[type]++, (ext) ? ext : ""); + CurrentPid, tmpf_seq[type]++, (ext) ? ext : ""); + pushText(fileToDelete, tmpf->ptr); return tmpf; } |