Commit 8e339303 authored by Karl Heuer's avatar Karl Heuer

(get_boot_time): Don't use BUFSIZ.

parent 75545902
......@@ -116,12 +116,12 @@ get_boot_time ()
while ((fd = open ("/proc/uptime", O_RDONLY)) >= 0)
{
char buf[BUFSIZ];
char buf[100];
int res;
double upsecs;
time_t uptime;
read (fd, buf, BUFSIZ);
read (fd, buf, sizeof buf);
close (fd);
res = sscanf (buf, "%lf", &upsecs);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment