diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2016-05-19 15:36:29 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2016-05-19 15:36:29 +0000 |
commit | 1ac13453fc246d8b2c5bcd2f5714c3871448f7a6 (patch) | |
tree | 34a5d8742ae0c63aa934b884beac255eea4aae5b | |
parent | c7a1ebebf38c3fff8e5c7477bdd0062068d32303 (diff) | |
download | aports-1ac13453fc246d8b2c5bcd2f5714c3871448f7a6.tar.bz2 aports-1ac13453fc246d8b2c5bcd2f5714c3871448f7a6.tar.xz |
main/busybox: better fix for touch -t
-rw-r--r-- | main/busybox/0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch | 32 | ||||
-rw-r--r-- | main/busybox/APKBUILD | 8 |
2 files changed, 15 insertions, 25 deletions
diff --git a/main/busybox/0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch b/main/busybox/0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch index 9bd5075454..3169bdff46 100644 --- a/main/busybox/0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch +++ b/main/busybox/0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch @@ -1,4 +1,4 @@ -From 1a3d9fb9074dc746326e6fa98c3eb499f6a6e048 Mon Sep 17 00:00:00 2001 +From c9ee7417d8d838c16bc2c270d4dbb5fdb9c8b786 Mon Sep 17 00:00:00 2001 From: Natanael Copa <ncopa@alpinelinux.org> Date: Thu, 19 May 2016 16:17:32 +0200 Subject: [PATCH] libbb: fix time parsing of [[CC]YY]MMDDhhmm[.SS] @@ -10,31 +10,21 @@ closes 8951 Signed-off-by: Natanael Copa <ncopa@alpinelinux.org> --- - libbb/time.c | 4 ++++ - 1 file changed, 4 insertions(+) + libbb/time.c | 1 + + 1 file changed, 1 insertion(+) diff --git a/libbb/time.c b/libbb/time.c -index aa19a47..44dd4aa 100644 +index aa19a47..82e6cb1 100644 --- a/libbb/time.c +++ b/libbb/time.c -@@ -159,6 +159,8 @@ void FAST_FUNC parse_datestr(const char *date_str, struct tm *ptm) - &ptm->tm_hour, - &ptm->tm_min, - &end) >= 5) { -+ /* assume zero if [.SS] is not given */ -+ ptm->tm_sec = 0; - /* Adjust month from 1-12 to 0-11 */ - ptm->tm_mon -= 1; - if ((int)cur_year >= 50) { /* >= 1950 */ -@@ -181,6 +183,8 @@ void FAST_FUNC parse_datestr(const char *date_str, struct tm *ptm) - &ptm->tm_hour, - &ptm->tm_min, - &end) >= 5) { -+ /* assume zero if [.SS] is not given */ -+ ptm->tm_sec = 0; - ptm->tm_year -= 1900; /* Adjust years */ - ptm->tm_mon -= 1; /* Adjust month from 1-12 to 0-11 */ +@@ -186,6 +186,7 @@ void FAST_FUNC parse_datestr(const char *date_str, struct tm *ptm) } else { + bb_error_msg_and_die(bb_msg_invalid_date, date_str); + } ++ ptm->tm_sec = 0; /* assume zero if [.SS] is not given */ + if (end == '.') { + /* xxx.SS */ + if (sscanf(strchr(date_str, '.') + 1, "%u%c", -- 2.8.2 diff --git a/main/busybox/APKBUILD b/main/busybox/APKBUILD index 0ab911c849..90602daf70 100644 --- a/main/busybox/APKBUILD +++ b/main/busybox/APKBUILD @@ -2,7 +2,7 @@ # Maintainer: Natanael Copa <ncopa@alpinelinux.org> pkgname=busybox pkgver=1.24.2 -pkgrel=3 +pkgrel=4 pkgdesc="Size optimized toolbox of many common UNIX utilities" url=http://busybox.net arch="all" @@ -182,7 +182,7 @@ f7c45568bdb0d2295c43108691e78a40 3002-libbb-allow_blank-argument-for-ask_and_ch f82d49c891c02516462db3cda29ccca7 3003-su-FEATURE_SU_NULLOK_SECURE.patch 5f03ee6f3e93bbc6aedff0777b227810 0001-ash-backport-fix-for-here-document-issues.patch a4d1cf64fd1835a284ccc6dbc78e3ce0 0001-ash-fix-error-during-recursive-processing-of-here-do.patch -6949aec16a6b18ff1b7ac6076abfb6b8 0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch +ab539a54dcd1c23eb0963e17e768fef7 0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch 4046b78ee6a25259954797d73b94f4bd acpid.logrotate 78724c22bb072eedf42fd17452bfe4d3 busyboxconfig befaac2c59c380e36a452b3f1c1d4a3a glibc.patch" @@ -210,7 +210,7 @@ ce24e38be870c90bdcb90e7b0445067adf7be0fac6b1154d2364a4db9ee3a9d8 3002-libbb-all d7b18672334ddeee7fbd6c0e92f26c5d2ef49ddefebf0b7f6eff8dc1ad8d3f7e 3003-su-FEATURE_SU_NULLOK_SECURE.patch f712ce190ce86084d56977e125d1561615394f3d9b840e926537868260e19d79 0001-ash-backport-fix-for-here-document-issues.patch 1d3f8f7b6d0972f8e56437fce8efbafe70e2d869fbe82f06eba11e0103fce224 0001-ash-fix-error-during-recursive-processing-of-here-do.patch -59b7cf87c94c87563dab99f70f6eabf7065b7357c6466a3e1c83b5abfaabb080 0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch +97dfec94c94f00b628a702ad81b235414af611e011bfc26c29be46c67063c101 0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch f7cbeb5a5a47395ad30454ce8262abcd3e91c33ef803c2ae31a9258d7142dd48 acpid.logrotate 529499778b833285d1cf821ef45dc1ef74f536fea010a43688e0bbab48c4c3a7 busyboxconfig c604ef791c31d35a8c5ee4558d21428a46f37a6d762c4a7e29864f4037fc44a0 glibc.patch" @@ -238,7 +238,7 @@ ed8d060b85d4da1681eb35ba64c5b249391e6a7edbeb55b8952897f08fe9bafac33593992772d80a c6579970450e7c711461ab1953f534ae855c4a355b4a452b3fc52a286355c87e41f8951b1b5217d0f659e3173ace8718d42dad3dcc878899cf9decdf4d3fe238 3003-su-FEATURE_SU_NULLOK_SECURE.patch d55cab6ed08434e2a278edf1be6171b921bcaee47598988e4de6b390a01569e10394c54d5d4a27e6eba251ce68df5cc1ece358be32a9c31bdf1f7e9147cf5180 0001-ash-backport-fix-for-here-document-issues.patch c14a632f9477c13ea99b24a73c81c9c44ead8b536970acd758e739b43a6260860039674341192ce7bb20a9204ee7d93dcd9541e526f2437d4d2d88637b400867 0001-ash-fix-error-during-recursive-processing-of-here-do.patch -814b34416ddf4ee16062ca3c128209fce392f40f33e5ee49fd7c81507bc16f9c112b1af9147cd45eb7d02ba943e1a111de50ab77a1bb827ca7152b8b77ab8e48 0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch +6fc77e0edcbb61a64c179b0259e0634a82362ac0ca9a77f305eb75f6a89a10395e8a37cbcef925821b428c00237a0a3575af2c3ef194933f52ad55b0eb0dd6f2 0001-libbb-fix-time-parsing-of-CC-YY-MMDDhhmm-.SS.patch dadb4c953ebc755b88ee95c1489feb0c2d352f6e44abc716166024e6eea11ab9d10c84fad62c081775834d205cb04aa1be3c994676c88f4284495c54b9188e8b acpid.logrotate ac26e4bf4ecbd3ba93db7e4665d6a58955596c87525ad0741f8e841bd803e67bd833407a037be44eca38eb7c2ec07250afe5beb58db8deef7aa838d81f8331d3 busyboxconfig 1d2739379dab1deb3eae7cffd4845300eb7d30f7343b4a1209b21a5680860d55080ad45fdefe098b249ce3040c01951fa7f0a79cd447b2d7b260eb000099d9dc glibc.patch" |