Deleted Added
full compact
ls.c (9987) ls.c (17534)
1/*
2 * Copyright (c) 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 68 unchanged lines hidden (view full) ---

77 (void)putchar('\n');
78}
79
80static void
81printtime(ftime)
82 time_t ftime;
83{
84 int i;
1/*
2 * Copyright (c) 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 68 unchanged lines hidden (view full) ---

77 (void)putchar('\n');
78}
79
80static void
81printtime(ftime)
82 time_t ftime;
83{
84 int i;
85 char *longstring, *ctime();
86 time_t time();
85 char longstring[80];
87
86
88 longstring = ctime((long *)&ftime);
87 strftime(longstring, sizeof(longstring), "%c", localtime(&ftime));
89 for (i = 4; i < 11; ++i)
90 (void)putchar(longstring[i]);
91
92#define SIXMONTHS ((365 / 2) * 86400)
93 if (ftime + SIXMONTHS > time((time_t *)NULL))
94 for (i = 11; i < 16; ++i)
95 (void)putchar(longstring[i]);
96 else {

--- 21 unchanged lines hidden ---
88 for (i = 4; i < 11; ++i)
89 (void)putchar(longstring[i]);
90
91#define SIXMONTHS ((365 / 2) * 86400)
92 if (ftime + SIXMONTHS > time((time_t *)NULL))
93 for (i = 11; i < 16; ++i)
94 (void)putchar(longstring[i]);
95 else {

--- 21 unchanged lines hidden ---