patch-2.4.17 linux/kernel/time.c
Next file: linux/mm/bootmem.c
Previous file: linux/kernel/sysctl.c
Back to the patch index
Back to the overall index
- Lines: 16
- Date:
Fri Dec 21 16:40:33 2001
- Orig file:
linux-2.4.16/kernel/time.c
- Orig date:
Mon Oct 16 19:58:51 2000
diff -Naur -X /home/marcelo/lib/dontdiff linux-2.4.16/kernel/time.c linux/kernel/time.c
@@ -70,11 +70,11 @@
*/
asmlinkage long sys_time(int * tloc)
{
- int i;
+ struct timeval now;
+ int i;
- /* SMP: This is fairly trivial. We grab CURRENT_TIME and
- stuff it to user space. No side effects */
- i = CURRENT_TIME;
+ do_gettimeofday(&now);
+ i = now.tv_sec;
if (tloc) {
if (put_user(i,tloc))
i = -EFAULT;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)