瀏覽代碼

Call setlocale and bindtextdomain in the http method

Matt Zimmerman 22 年之前
父節點
當前提交
049c0171c2
共有 2 個文件被更改,包括 5 次插入 和 1 次删除
  1. 2 1
      debian/changelog
  2. 3 0
      methods/http.cc

+ 2 - 1
debian/changelog

@@ -1,6 +1,7 @@
 apt (0.5.32) unstable; urgency=low
 
-  * 
+  * Call setlocale and bindtextdomain in the http method, so that the
+    messages are properly localised (Closes: #282700)
 
  --
 

+ 3 - 0
methods/http.cc

@@ -1183,6 +1183,9 @@ int HttpMethod::Loop()
 
 int main()
 {
+   setlocale(LC_ALL, "");
+   bindtextdomain(APT_DOMAIN, Cnf.FindDir("Dir::Locale").c_str());
+
    HttpMethod Mth;
    
    return Mth.Loop();