誰かがこれを説明できますか?時刻が 1 または 2 の場合にのみ、「無効な日付」を返します。午前 3 時以降は、UNIX タイム スタンプへの変換を行います。
[user@localhost ~]$ date --version
date (GNU coreutils) 8.4
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by David MacKenzie.
[user@localhost ~]$ date --date="Sun Mar 10 01:59:00 PDT 2013" +%s
date: invalid date `Sun Mar 10 01:59:00 PDT 2013'
[user@localhost ~]$ date --date="Sun Mar 10 02:59:00 PDT 2013" +%s
date: invalid date `Sun Mar 10 02:59:00 PDT 2013'
[user@localhost ~]$ date --date="Sun Mar 10 03:59:00 PDT 2013" +%s
1362913140
[user@localhost ~]$ date --date="Sun Mar 10 04:59:00 PDT 2013" +%s
1362916740
ありがとう!