You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

38 lines
1.3 KiB

# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../lua-posix/clk_tck.patch
# Copyright (C) 2006 The T2 SDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
diff -ur posix/lposix.c posix-t2/lposix.c
--- posix/lposix.c 2003-11-06 01:23:48.000000000 +0100
+++ posix-t2/lposix.c 2006-02-01 22:15:50.000000000 +0100
@@ -599,7 +599,7 @@
clock_t elapsed;
};
-#define pushtime(L,x) lua_pushnumber(L,((lua_Number)x)/CLK_TCK)
+#define pushtime(L,x) lua_pushnumber(L,((lua_Number)x)/CLOCKS_PER_SEC)
static int Ftimes(lua_State *L, int i, const void *data)
{
@@ -620,7 +620,7 @@
"utime", "stime", "cutime", "cstime", "elapsed", NULL
};
-#define storetime(L,name,x) storenumber(L,name,(lua_Number)x/CLK_TCK)
+#define storetime(L,name,x) storenumber(L,name,(lua_Number)x/CLOCKS_PER_SEC)
static int Ptimes(lua_State *L) /** times() */
{