mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-01-27 19:41:56 +01:00
21 lines
414 B
Diff
21 lines
414 B
Diff
diff --git a/src/lua-apk.c b/src/lua-apk.c
|
|
index 532577a..26129fb 100644
|
|
--- a/src/lua-apk.c
|
|
+++ b/src/lua-apk.c
|
|
@@ -37,6 +37,15 @@ struct flagmap opendb_flagmap[] = {
|
|
{NULL, 0}
|
|
};
|
|
|
|
+time_t apk_time(void)
|
|
+{
|
|
+#ifdef TEST_MODE
|
|
+ return 1559567666;
|
|
+#else
|
|
+ return time(NULL);
|
|
+#endif
|
|
+}
|
|
+
|
|
/* implemented as luaL_typerror until lua 5.1, dropped in 5.2
|
|
* (C) 1994-2012 Lua.org, PUC-Rio. MIT license
|
|
*/
|