COOPY » Guide  version 0.6.5
Defines | Functions
/home/paulfitz/cvs/coopy_scm/coopy/src/libcoopy_core/gnulib/tmpdir.c File Reference
#include "tmpdir.h"
#include <stdbool.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <stdio.h>
#include <sys/stat.h>
#include "pathmax.h"

Go to the source code of this file.

Defines

#define __set_errno(Val)   errno = (Val)
#define P_tmpdir   "/tmp"
#define struct_stat64   struct stat
#define __xstat64(version, path, buf)   stat (path, buf)
#define __secure_getenv   getenv
#define ISSLASH(C)   ((C) == '/')

Functions

static bool direxists (const char *dir)
int path_search (char *tmpl, size_t tmpl_len, const char *dir, const char *pfx, bool try_tmpdir)

Define Documentation

#define __secure_getenv   getenv

Definition at line 60 of file tmpdir.c.

Referenced by path_search().

#define __set_errno (   Val)    errno = (Val)

Definition at line 31 of file tmpdir.c.

Referenced by path_search().

#define __xstat64 (   version,
  path,
  buf 
)    stat (path, buf)

Definition at line 56 of file tmpdir.c.

Referenced by direxists().

#define ISSLASH (   C)    ((C) == '/')

Definition at line 71 of file tmpdir.c.

Referenced by path_search().

#define P_tmpdir   "/tmp"

Definition at line 39 of file tmpdir.c.

Referenced by path_search().

#define struct_stat64   struct stat

Definition at line 55 of file tmpdir.c.

Referenced by direxists().


Function Documentation

static bool direxists ( const char *  dir) [static]

Definition at line 77 of file tmpdir.c.

References __xstat64, and struct_stat64.

Referenced by path_search().

int path_search ( char *  tmpl,
size_t  tmpl_len,
const char *  dir,
const char *  pfx,
bool  try_tmpdir 
)

Definition at line 90 of file tmpdir.c.

References __secure_getenv, __set_errno, direxists(), ISSLASH, NULL, and P_tmpdir.

Referenced by coopy::os::OS::getTemporaryFilename().

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines