aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2018-07-11 22:20:32 +0200
committerJustin M. Keyes <justinkz@gmail.com>2018-07-24 19:25:50 +0200
commitddea51954259597ce5efd03d3de34fd0fa91d1d3 (patch)
treebbf656dd4945bada222652797d7dfad6285a3a28 /src
parent72ddbb675fc9cd649feeddef754b65c08bbf21ba (diff)
downloadrneovim-ddea51954259597ce5efd03d3de34fd0fa91d1d3.tar.gz
rneovim-ddea51954259597ce5efd03d3de34fd0fa91d1d3.tar.bz2
rneovim-ddea51954259597ce5efd03d3de34fd0fa91d1d3.zip
rename: os_get_localtime => os_localtime
Diffstat (limited to 'src')
-rw-r--r--src/nvim/log.c2
-rw-r--r--src/nvim/os/time.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/log.c b/src/nvim/log.c
index 7bfe5c4089..ef5b7699af 100644
--- a/src/nvim/log.c
+++ b/src/nvim/log.c
@@ -262,7 +262,7 @@ static bool v_do_log_to_file(FILE *log_file, int log_level,
// format current timestamp in local time
struct tm local_time;
- if (os_get_localtime(&local_time) == NULL) {
+ if (os_localtime(&local_time) == NULL) {
return false;
}
char date_time[20];
diff --git a/src/nvim/os/time.c b/src/nvim/os/time.c
index 290d421acc..31ef1a0cd6 100644
--- a/src/nvim/os/time.c
+++ b/src/nvim/os/time.c
@@ -114,12 +114,12 @@ struct tm *os_localtime_r(const time_t *restrict clock,
#endif
}
-/// Obtains the current Unix timestamp and adjusts it to local time.
+/// Gets the current Unix timestamp and adjusts it to local time.
///
/// @param result Pointer to a 'struct tm' where the result should be placed
/// @return A pointer to a 'struct tm' in the current time zone (the 'result'
/// argument) or NULL in case of error
-struct tm *os_get_localtime(struct tm *result) FUNC_ATTR_NONNULL_ALL
+struct tm *os_localtime(struct tm *result) FUNC_ATTR_NONNULL_ALL
{
time_t rawtime = time(NULL);
return os_localtime_r(&rawtime, result);