The Samba-Bugzilla – Attachment 2829 Details for
Bug 4402
Incorrect time logged with glibc 2.5 inside chroot area
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Chroot + timezone test program
chroot-timezone.c (text/x-csrc), 583 bytes, created by
Matt McCutchen
on 2007-07-18 13:41:58 UTC
(
hide
)
Description:
Chroot + timezone test program
Filename:
MIME Type:
Creator:
Matt McCutchen
Created:
2007-07-18 13:41:58 UTC
Size:
583 bytes
patch
obsolete
>#include <unistd.h> >#include <time.h> >#include <stdio.h> >#include <sys/time.h> > >int main() { > time_t time1; > struct tm tm; > char timestr[100]; > struct timeval tv; > > time(&time1); > localtime_r(&time1, &tm); > strftime(timestr, sizeof timestr, "%Y/%m/%d %H:%M:%S", &tm); > printf("%s\n", timestr); > > gettimeofday(&tv, NULL); > > if (chroot("/home/matt/test/jail") < 0) { > perror("chroot"); > return 1; > } > sleep(2); > > gettimeofday(&tv, NULL); > > time(&time1); > localtime_r(&time1, &tm); > strftime(timestr, sizeof timestr, "%Y/%m/%d %H:%M:%S", &tm); > printf("%s\n", timestr); > > return 0; >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 4402
: 2829 |
2836