From: Michael Andres Date: Fri, 16 Nov 2007 14:50:36 +0000 (+0000) Subject: reset LC_TIME X-Git-Tag: BASE-SuSE-Linux-11_0-Branch~686 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=62d59c774724b7293ea8a474b01c6df0b6e82940;p=platform%2Fupstream%2Flibzypp.git reset LC_TIME --- diff --git a/zypp/Date.cc b/zypp/Date.cc index 36501ac..d5f2240 100644 --- a/zypp/Date.cc +++ b/zypp/Date.cc @@ -70,10 +70,20 @@ namespace zypp } ::setlocale( LC_TIME, needLocale.c_str() ); } + else + { + // no need to change the locale + thisLocale.clear(); + } if ( ! strftime( buf, 1024, format_r.c_str(), localtime( &_date ) ) ) *buf = '\0'; + if ( ! thisLocale.empty() ) + { + ::setlocale( LC_TIME, thisLocale.c_str() ); + } + return buf; }