Software: Apache/2.2.3 (CentOS). PHP/5.1.6 uname -a: Linux mx-ll-110-164-51-230.static.3bb.co.th 2.6.18-194.el5PAE #1 SMP Fri Apr 2 15:37:44 uid=48(apache) gid=48(apache) groups=48(apache) Safe-mode: OFF (not secure) /usr/share/doc/netpbm-10.35.58/userguide/ drwxr-xr-x |
Viewing file: libmaketmpfile.html (2.43 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) | pm_make_tmpfile()Updated: 10 November 2007NAMEpm_make_tmpfile() - create a temporary named fileSYNOPSIS#include <netpbm/pm.h> pm_make_tmpfile(FILE ** fileP, const char ** filenameP); EXAMPLEThis simple example creates a temporary file, writes "hello world" to it, then writes some search patterns to it, then uses it as input to grep: #include <netpbm/pm.h> FILE * myfileP; const char * myfilename; pm_make_tmpfile(&myfileP, &myfilename); fprintf(myfile, "^account:\\s.*\n"); fprintf(myfile, "^name:\\s.*\n"); fclose(myFileP); asprintfN(&grepCommand, "grep --file='%s' /tmp/infile >/tmp/outfile"); system(grepCommand); strfree(grepCommand); unlink(myfilename); strfree(myfilename); DESCRIPTIONThis library function is part of Netpbm. pm_make_tmpfile() creates and opens a temporary file, returning to you a stream file handle for it and its name. pm_make_tmpfile() chooses a file name that is not already in use, with proper interlocking to make sure that it actually creates a file and opens the new file, as opposed to merely opening an existing file. If you don't need to access the file by name, use pm_tmpfile() instead, because it's cleaner. With pm_tmpfile(), the operating system always deletes the temporary file when your program exits, if the program failed to clean up after itself. The temporary file goes in the directory named by the TMPFILE environment variable. If TMPFILE is not set or is set to something unusable (e.g. too long), pm_tmpfile() falls back to the value of the standard C library symbol P_tmpdir (like the standard C library's tmpfile()). The name of the file within that directory is like myprog_blrfx, where myprog is the name of your program (arg 0) and the rest is an arbitrary discriminator. If pm_make_tmpfile() is unable to create a temporary file, it issues a message to Standard Error and aborts the program. HISTORYpm_tmpfile() was introduced in Netpbm 10.27 (March 2005). |
:: Command execute :: | |
:: Shadow's tricks :D :: | |
Useful Commands
|
:: Preddy's tricks :D :: | |
Php Safe-Mode Bypass (Read Files)
|
--[ c999shell v. 1.0 pre-release build #16 Modded by Shadow & Preddy | RootShell Security Group | r57 c99 shell | Generation time: 0.0171 ]-- |