Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
86767f4a
Commit
86767f4a
authored
Jul 24, 2019
by
Marko Mäkelä
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unused ut_get_year_month_day()
parent
c83663e5
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
2 additions
and
92 deletions
+2
-92
storage/innobase/include/ut0ut.h
storage/innobase/include/ut0ut.h
+1
-9
storage/innobase/ut/ut0ut.cc
storage/innobase/ut/ut0ut.cc
+0
-37
storage/xtradb/include/ut0ut.h
storage/xtradb/include/ut0ut.h
+1
-9
storage/xtradb/ut/ut0ut.cc
storage/xtradb/ut/ut0ut.cc
+0
-37
No files found.
storage/innobase/include/ut0ut.h
View file @
86767f4a
/*****************************************************************************
Copyright (c) 1994, 2017, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2019, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
...
...
@@ -343,15 +344,6 @@ void
ut_sprintf_timestamp_without_extra_chars
(
/*=====================================*/
char
*
buf
);
/*!< in: buffer where to sprintf */
/**********************************************************//**
Returns current year, month, day. */
UNIV_INTERN
void
ut_get_year_month_day
(
/*==================*/
ulint
*
year
,
/*!< out: current year */
ulint
*
month
,
/*!< out: month */
ulint
*
day
);
/*!< out: day */
#else
/* UNIV_HOTBACKUP */
/*************************************************************//**
Runs an idle loop on CPU. The argument gives the desired delay
...
...
storage/innobase/ut/ut0ut.cc
View file @
86767f4a
...
...
@@ -344,43 +344,6 @@ ut_sprintf_timestamp_without_extra_chars(
cal_tm_ptr
->
tm_sec
);
#endif
}
/**********************************************************//**
Returns current year, month, day. */
UNIV_INTERN
void
ut_get_year_month_day
(
/*==================*/
ulint
*
year
,
/*!< out: current year */
ulint
*
month
,
/*!< out: month */
ulint
*
day
)
/*!< out: day */
{
#ifdef __WIN__
SYSTEMTIME
cal_tm
;
GetLocalTime
(
&
cal_tm
);
*
year
=
(
ulint
)
cal_tm
.
wYear
;
*
month
=
(
ulint
)
cal_tm
.
wMonth
;
*
day
=
(
ulint
)
cal_tm
.
wDay
;
#else
struct
tm
*
cal_tm_ptr
;
time_t
tm
;
#ifdef HAVE_LOCALTIME_R
struct
tm
cal_tm
;
time
(
&
tm
);
localtime_r
(
&
tm
,
&
cal_tm
);
cal_tm_ptr
=
&
cal_tm
;
#else
time
(
&
tm
);
cal_tm_ptr
=
localtime
(
&
tm
);
#endif
*
year
=
(
ulint
)
cal_tm_ptr
->
tm_year
+
1900
;
*
month
=
(
ulint
)
cal_tm_ptr
->
tm_mon
+
1
;
*
day
=
(
ulint
)
cal_tm_ptr
->
tm_mday
;
#endif
}
#endif
/* UNIV_HOTBACKUP */
#ifndef UNIV_HOTBACKUP
...
...
storage/xtradb/include/ut0ut.h
View file @
86767f4a
/*****************************************************************************
Copyright (c) 1994, 2017, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2019, MariaDB Corporation.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
...
...
@@ -343,15 +344,6 @@ void
ut_sprintf_timestamp_without_extra_chars
(
/*=====================================*/
char
*
buf
);
/*!< in: buffer where to sprintf */
/**********************************************************//**
Returns current year, month, day. */
UNIV_INTERN
void
ut_get_year_month_day
(
/*==================*/
ulint
*
year
,
/*!< out: current year */
ulint
*
month
,
/*!< out: month */
ulint
*
day
);
/*!< out: day */
#else
/* UNIV_HOTBACKUP */
/*************************************************************//**
Runs an idle loop on CPU. The argument gives the desired delay
...
...
storage/xtradb/ut/ut0ut.cc
View file @
86767f4a
...
...
@@ -368,43 +368,6 @@ ut_sprintf_timestamp_without_extra_chars(
cal_tm_ptr
->
tm_sec
);
#endif
}
/**********************************************************//**
Returns current year, month, day. */
UNIV_INTERN
void
ut_get_year_month_day
(
/*==================*/
ulint
*
year
,
/*!< out: current year */
ulint
*
month
,
/*!< out: month */
ulint
*
day
)
/*!< out: day */
{
#ifdef __WIN__
SYSTEMTIME
cal_tm
;
GetLocalTime
(
&
cal_tm
);
*
year
=
(
ulint
)
cal_tm
.
wYear
;
*
month
=
(
ulint
)
cal_tm
.
wMonth
;
*
day
=
(
ulint
)
cal_tm
.
wDay
;
#else
struct
tm
*
cal_tm_ptr
;
time_t
tm
;
#ifdef HAVE_LOCALTIME_R
struct
tm
cal_tm
;
time
(
&
tm
);
localtime_r
(
&
tm
,
&
cal_tm
);
cal_tm_ptr
=
&
cal_tm
;
#else
time
(
&
tm
);
cal_tm_ptr
=
localtime
(
&
tm
);
#endif
*
year
=
(
ulint
)
cal_tm_ptr
->
tm_year
+
1900
;
*
month
=
(
ulint
)
cal_tm_ptr
->
tm_mon
+
1
;
*
day
=
(
ulint
)
cal_tm_ptr
->
tm_mday
;
#endif
}
#endif
/* UNIV_HOTBACKUP */
#ifndef UNIV_HOTBACKUP
...
...
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