aboutsummaryrefslogtreecommitdiff
path: root/toys/posix/touch.c
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2012-11-16 15:44:45 -0600
committerRob Landley <rob@landley.net>2012-11-16 15:44:45 -0600
commit47ee6f300326f65fe4dfcee5470f1f99018d442a (patch)
tree9eaab3e3f14c2b1fbd777072d1718af8b141734c /toys/posix/touch.c
parentf6261b3a80a29da78d8b6976ceeb71dcb30f3745 (diff)
downloadtoybox-47ee6f300326f65fe4dfcee5470f1f99018d442a.tar.gz
Fix touch warnings (unused variables, failure to reserve space for null terminator).
Diffstat (limited to 'toys/posix/touch.c')
-rw-r--r--toys/posix/touch.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/toys/posix/touch.c b/toys/posix/touch.c
index 9b8f7932..30e3748f 100644
--- a/toys/posix/touch.c
+++ b/toys/posix/touch.c
@@ -46,12 +46,8 @@ int check_date_format(char *date_input)
time_t get_time_sec(char *date_input)
{
int count_date_digit = 0;
- char temp_date[12];
- char mm[2];
- char dd[2];
- char hh[2];
- char ss[2];
- char year[4];
+ char mm[3];
+ char year[5];
time_t time_of_modify;
struct tm t_yyyymmddhhss;