|
2013-11-12
| ||
| 12:37 | • Closed ticket [3531146fff]: clock scan does not error when missing undelimited f... artifact: dc90226379 user: dkf | |
|
2012-06-01
| ||
| 13:34 | • Pending ticket [3531146fff]. artifact: e901fec5b4 user: sebres | |
| 01:54 | • Ticket [3531146fff]: 4 changes artifact: fa6c7a048d user: bovineone | |
|
2012-05-31
| ||
| 18:24 | • New ticket [3531146fff]. artifact: 39967038ef user: bovineone | |
clock scan does not error when missing undelimited fields
Closed / Duplicate3531146fffffffffffffffffffffffffffffffffCreated 15 years agoUpdated 13 years ago
Descriptionplain2012-05-31 18:24:56
In the following example, the first string being parsed is missing the seconds needed for the %S parameter, so it chooses to put one of the digits in the minutes field and one of them in the seconds field instead: clock scan "1205311743" -format "%y%m%d%H%M%S" -gmt 1 1338483843 clock format 1338483843 -gmt 1 Thu May 31 17:04:03 GMT 2012 The expected behavior would probably to treat the missing seconds as zero, or to raise an error: clock scan "120531174300" -format "%y%m%d%H%M%S" -gmt 1 1338486180
bovineoneplain2012-06-01 01:54:06
Note that the documentation for clock says that both %M and %S only accept 2 digits on input (and not 1 or 2 digits).
sebresplain2012-06-01 13:34:41
duplicate of 3475995 (already solved - see attached patch in it, but not yet in branch).
dkf Closed ticket [3531146fff].
[History diff]2013-11-12 12:37:01
Log in (anonymous is fine) to add a comment.