Skip to contentSkip to conversation

Fix an bad variable name erro in runltp script

PATCH [email protected] 1 participant 1 message May 5, 2014 1 message not in the archive

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive

Hi!

Review

Quoted 9 lines

I got an error for the latest version 20140115 of ltp project. This error was found in my os, I use zh_CN for default language,
the date +"%Y_%b_%d-%Hh_%Mm_%Ss" will get like "2014_ 4yue_11-09h_36m_52s", it contain a space before "4yue" will get the bad variable name error.

I fix this error and change the date args, see detail below:

(quoted diff) +1 -1
-    local DEFAULT_FILE_NAME_GENERATION_TIME=`date +"%Y_%b_%d-%Hh_%Mm_%Ss"`
+    local DEFAULT_FILE_NAME_GENERATION_TIME=`date +"%Y_%m_%d-%Hh_%Mm_%Ss"`

I've reworded the summary a bit, added quotes around the variable and pushed, thanks.

PS: I've been unable to reproduce the bug, for me date +%b does not add
a space before the month even with LC_ALL=zh_CN, but IMHO number is better than month abbreviation that is different for each language.

Signature · 13 lines
Cyril Hrubis
[email protected]

------------------------------------------------------------------------------
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list