dc_datetime_mktime man page

dc_datetime_mktime — convert an local date and time to a timestamp

Library

library “libdivecomputer”

Synopsis

#include <libdivecomputer/datetime.h>

dc_ticks_t
dc_datetime_mktime(const dc_datetime_t *dt);

Description

Convert a broken-down local date and time created with dc_datetime_localtime(3) into an integral timestamp.

The dc_datetime_mktime function may internally invoke libc's mktime(3).

Return Values

This returns the integral time-stamp or -1 if the given date and time may not sanely be converted.

See Also

dc_datetime_gmtime(3), dc_datetime_localtime(3), dc_datetime_new(3)

Authors

The library “libdivecomputer” library was written by Jef Driesen, jef@libdivecomputer.org. The manpages were written by
Kristaps Dzonsons, kristaps@bsd.lv.

Referenced By

dc_datetime_gmtime(3), dc_datetime_localtime(3), dc_datetime_now(3).

January 11, 2017