Mercurial > vim
comparison src/os_unix.h @ 18669:9007e9896303 v8.1.2326
patch 8.1.2326: cannot parse a date/time string
Commit: https://github.com/vim/vim/commit/10455d43fef041309ce0613fa792c635dd71e3a8
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Nov 21 15:36:18 2019 +0100
patch 8.1.2326: cannot parse a date/time string
Problem: Cannot parse a date/time string.
Solution: Add strptime(). (Stephen Wall, closes #)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 21 Nov 2019 15:45:03 +0100 |
parents | 8f4cc259ed7a |
children | 673f4603d979 |
comparison
equal
deleted
inserted
replaced
18668:ce55d198b1b5 | 18669:9007e9896303 |
---|---|
125 # if HAVE_NDIR_H | 125 # if HAVE_NDIR_H |
126 # include <ndir.h> | 126 # include <ndir.h> |
127 # endif | 127 # endif |
128 #endif | 128 #endif |
129 | 129 |
130 // on some systems time.h should not be included together with sys/time.h | |
130 #if !defined(HAVE_SYS_TIME_H) || defined(TIME_WITH_SYS_TIME) | 131 #if !defined(HAVE_SYS_TIME_H) || defined(TIME_WITH_SYS_TIME) |
131 # include <time.h> /* on some systems time.h should not be | 132 // Needed for strptime() |
132 included together with sys/time.h */ | 133 # ifndef _XOPEN_SOURCE |
134 # define _XOPEN_SOURCE | |
135 # endif | |
136 # ifndef __USE_XOPEN | |
137 # define __USE_XOPEN | |
138 # endif | |
139 # include <time.h> | |
133 #endif | 140 #endif |
134 #ifdef HAVE_SYS_TIME_H | 141 #ifdef HAVE_SYS_TIME_H |
135 # include <sys/time.h> | 142 # include <sys/time.h> |
136 #endif | 143 #endif |
137 | 144 |