Back to index

nagios-plugins  1.4.16
Functions
time_r.c File Reference
#include <config.h>
#include <time.h>

Go to the source code of this file.

Functions

static struct tm * copy_tm_result (struct tm *dest, struct tm const *src)
struct tm * gmtime_r (time_t const *restrict t, struct tm *restrict tp)
struct tm * localtime_r (time_t const *restrict t, struct tm *restrict tp)

Function Documentation

static struct tm* copy_tm_result ( struct tm *  dest,
struct tm const src 
) [static, read]

Definition at line 26 of file time_r.c.

{
  if (! src)
    return 0;
  *dest = *src;
  return dest;
}

Here is the caller graph for this function:

struct tm* gmtime_r ( time_t const *restrict  t,
struct tm *restrict  tp 
) [read]

Definition at line 36 of file time_r.c.

{
  return copy_tm_result (tp, gmtime (t));
}

Here is the call graph for this function:

struct tm* localtime_r ( time_t const *restrict  t,
struct tm *restrict  tp 
) [read]

Definition at line 42 of file time_r.c.

{
  return copy_tm_result (tp, localtime (t));
}

Here is the call graph for this function: