Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
captainwong
jlib
Commits
37f8dbe7
Commit
37f8dbe7
authored
Nov 22, 2023
by
captainwong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix chrono wrapper linux build
parent
c9174ca4
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
130 additions
and
124 deletions
+130
-124
chrono_wrapper.h
jlib/util/chrono_wrapper.h
+130
-124
No files found.
jlib/util/chrono_wrapper.h
View file @
37f8dbe7
#
pragma
once
#
pragma
once
#include "../base/config.h"
#include "../base/config.h"
#ifdef __GNUG__
#include <string.h> // memcpy
#endif
#include <chrono>
#include <chrono>
#include <string>
#include <string>
#include <ctime>
#include <ctime>
...
@@ -10,6 +15,7 @@
...
@@ -10,6 +15,7 @@
namespace
jlib
{
namespace
jlib
{
#ifdef __GNUG__
#ifdef __GNUG__
#include <string.h> // memcpy
inline
void
localtime_s
(
struct
tm
*
tmtm
,
const
time_t
*
t
)
{
inline
void
localtime_s
(
struct
tm
*
tmtm
,
const
time_t
*
t
)
{
memcpy
(
tmtm
,
localtime
(
t
),
sizeof
(
tm
));
memcpy
(
tmtm
,
localtime
(
t
),
sizeof
(
tm
));
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment