diff options
-rw-r--r-- | apt-pkg/contrib/progress.cc | 4 | ||||
-rw-r--r-- | apt-pkg/indexrecords.cc | 5 | ||||
-rw-r--r-- | debian/apt.cron.daily | 2 | ||||
-rw-r--r-- | debian/changelog | 27 | ||||
-rwxr-xr-x | debian/rules | 2 | ||||
-rw-r--r-- | doc/makefile | 2 | ||||
-rw-r--r-- | doc/po/it.po | 4 | ||||
-rw-r--r-- | methods/http.cc | 6 | ||||
-rw-r--r-- | methods/https.cc | 4 | ||||
-rw-r--r-- | methods/https.h | 5 | ||||
-rw-r--r-- | po/ja.po | 12 |
11 files changed, 56 insertions, 17 deletions
diff --git a/apt-pkg/contrib/progress.cc b/apt-pkg/contrib/progress.cc index 317048845..17a6b70e9 100644 --- a/apt-pkg/contrib/progress.cc +++ b/apt-pkg/contrib/progress.cc @@ -176,7 +176,7 @@ void OpTextProgress::Update() if (OldOp.empty() == false) cout << endl; OldOp = "a"; - cout << Op << "..." << flush; + cout << Op << _("...") << flush; } return; @@ -192,7 +192,7 @@ void OpTextProgress::Update() } // Print the spinner - snprintf(S,sizeof(S),"\r%s... %u%%",Op.c_str(),(unsigned int)Percent); + snprintf(S,sizeof(S),_("\r%s... %u%%"),Op.c_str(),(unsigned int)Percent); Write(S); OldOp = Op; diff --git a/apt-pkg/indexrecords.cc b/apt-pkg/indexrecords.cc index af2639beb..649b6059d 100644 --- a/apt-pkg/indexrecords.cc +++ b/apt-pkg/indexrecords.cc @@ -173,7 +173,7 @@ bool indexRecords::parseSumData(const char *&Start, const char *End, /*{{{*/ Hash = ""; Size = 0; /* Skip over the first blank */ - while ((*Start == '\t' || *Start == ' ' || *Start == '\n') + while ((*Start == '\t' || *Start == ' ' || *Start == '\n' || *Start == '\r') && Start < End) Start++; if (Start >= End) @@ -215,7 +215,8 @@ bool indexRecords::parseSumData(const char *&Start, const char *End, /*{{{*/ EntryEnd = Start; /* Find the end of the third entry (the filename) */ - while ((*EntryEnd != '\t' && *EntryEnd != ' ' && *EntryEnd != '\n') + while ((*EntryEnd != '\t' && *EntryEnd != ' ' && + *EntryEnd != '\n' && *EntryEnd != '\r') && EntryEnd < End) EntryEnd++; diff --git a/debian/apt.cron.daily b/debian/apt.cron.daily index 5c00f22db..2665b6579 100644 --- a/debian/apt.cron.daily +++ b/debian/apt.cron.daily @@ -289,7 +289,7 @@ random_sleep() fi if [ -z "$RANDOM" ] ; then # A fix for shells that do not have this bash feature. - RANDOM=$(dd if=/dev/urandom count=1 2> /dev/null | cksum | cut -c"1-5") + RANDOM=$(( $(dd if=/dev/urandom bs=2 count=1 2> /dev/null | cksum | cut -d' ' -f1) % 32767 )) fi TIME=$(($RANDOM % $RandomSleep)) debug_echo "sleeping for $TIME seconds" diff --git a/debian/changelog b/debian/changelog index 6f611f2f5..9f4dca04e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -25,11 +25,38 @@ apt (0.9.7.8) UNRELEASED; urgency=low [ Manpages translation updates ] * Italian (Beatrice Torracca). Closes: #696601 + [ Programs translation updates ] + * Japanese (Kenshi Muto). Closes: #699783 + [ Michael Vogt ] * fix pkgProblemResolver::Scores, thanks to Paul Wise. Closes: #697577 * [ABI BREAK] apt-pkg/pkgcache.h: - adjust pkgCache::State::VerPriority enum, to match reality + * fix missing translated apt.8 manpages, thanks to Helge Kreutzmann + for the report. Closes: #696923 + * apt-pkg/contrib/progress.cc: + - Make "..." translatable to fix inconsistencies in the output + of e.g. apt-get update. While this adds new translatable strings, + not having translations for them will not break anything. + Thanks to Guillem Jover. Closes: #696225 + * debian/apt.cron.daily: + - when reading from /dev/urandom, use less entropy and fix a rare + bug when the random number chksum is less than 1000. + Closes: #695285 + * methods/https.cc: + - reuse connection in https, thanks to Thomas Bushnell, BSG for the + patch. LP: #1087543, Closes: #695359 + - add missing curl_easy_cleanup() + * methods/http.cc: + - quote spaces in filenames to ensure as the http method is also + (potentially) used for non deb,dsc content that may contain + spaces, thanks to Daniel Hartwig and Thomas Bushnell + (LP: #1086997) + - quote plus in filenames to work around a bug in the S3 server + (LP: #1003633) + * apt-pkg/indexrecords.cc: + - support '\r' in the Release file -- Christian Perrier <bubulle@debian.org> Mon, 24 Dec 2012 07:01:20 +0100 diff --git a/debian/rules b/debian/rules index 83e23881c..5051dab4f 100755 --- a/debian/rules +++ b/debian/rules @@ -172,7 +172,7 @@ apt-doc: build-debiandoc # Build architecture-dependent files here. binary-arch: $(LIBAPT_PKG) $(LIBAPT_INST) apt libapt-pkg-dev apt-utils apt-transport-https -apt_MANPAGES = apt-cache apt-cdrom apt-config apt-get apt-key apt-mark apt-secure apt apt.conf apt_preferences sources.list +apt_MANPAGES = apt apt-cache apt-cdrom apt-config apt-get apt-key apt-mark apt-secure apt apt.conf apt_preferences sources.list apt: build build-manpages dh_testdir -p$@ dh_testroot -p$@ diff --git a/doc/makefile b/doc/makefile index 8021bce3f..be8357d80 100644 --- a/doc/makefile +++ b/doc/makefile @@ -87,7 +87,9 @@ update-po: --msgid-bugs-address='$(PACKAGE_MAIL)' po4a.conf $(MANPAGEPOLIST) :: manpages-translation-% : %/makefile po4a.conf + # first line is for apt.8 (see Bug#696923) po4a --previous --no-backups --translate-only $(dir $<)apt.ent \ + $(patsubst %,--translate-only $(dir $<)%,$(patsubst %.8,%.$(subst /,,$(dir $<)).8,$(wildcard *.8))) \ $(patsubst %,--translate-only $(dir $<)%,$(patsubst %.1.xml,%.$(subst /,,$(dir $<)).1.xml,$(wildcard *.1.xml))) \ $(patsubst %,--translate-only $(dir $<)%,$(patsubst %.2.xml,%.$(subst /,,$(dir $<)).2.xml,$(wildcard *.2.xml))) \ $(patsubst %,--translate-only $(dir $<)%,$(patsubst %.3.xml,%.$(subst /,,$(dir $<)).3.xml,$(wildcard *.3.xml))) \ diff --git a/doc/po/it.po b/doc/po/it.po index a4d8d0ccc..544263d0d 100644 --- a/doc/po/it.po +++ b/doc/po/it.po @@ -1001,7 +1001,7 @@ msgid "" "literal>, the <option>-t</option> option or per package with the " "<literal>pkg/release</literal> syntax, if possible." msgstr "" -"<literal>source</literal> fa sì che </command>apt-get</command> scarichi i " +"<literal>source</literal> fa sì che <command>apt-get</command> scarichi i " "pacchetti sorgente. APT esaminerà i pacchetti disponibili per decidere quali " "pacchetti sorgente scaricare. Poi, se possibile, troverà e scaricherà nella " "directory corrente la versione più recente disponibile di quel pacchetto " @@ -6965,7 +6965,7 @@ msgid "" msgstr "" "APT può essere esteso con ulteriori metodi forniti in altri pacchetti " "opzionali, i cui nomi devono seguire lo schema <package>apt-" -"transport-<replaceable>metodo</replaceable>. Per esempio, il team di APT " +"transport-<replaceable>metodo</replaceable></package>. Per esempio, il team di APT " "mantiene anche il pacchetto <package>apt-transport-https</package> che " "fornisce i metodi di accesso per URI HTTPS con funzionalità simili a quelle " "del metodo http. Sono disponibili anche i metodi per usare, ad esempio, " diff --git a/methods/http.cc b/methods/http.cc index acf25a42a..fddf8a78e 100644 --- a/methods/http.cc +++ b/methods/http.cc @@ -685,8 +685,12 @@ void HttpMethod::SendReq(FetchItem *Itm,CircleBuf &Out) pass it on, HTTP/1.1 says the connection should default to keep alive and we expect the proxy to do this */ if (Proxy.empty() == true || Proxy.Host.empty()) + { + // see LP bugs #1003633 and #1086997. The "+" is encoded as a workaround + // for a amazon S3 bug sprintf(Buf,"GET %s HTTP/1.1\r\nHost: %s\r\nConnection: keep-alive\r\n", - QuoteString(Uri.Path,"~").c_str(),ProperHost.c_str()); + QuoteString(Uri.Path,"+~ ").c_str(),ProperHost.c_str()); + } else { /* Generate a cache control header if necessary. We place a max diff --git a/methods/https.cc b/methods/https.cc index c1a49ba60..11d4ba8aa 100644 --- a/methods/https.cc +++ b/methods/https.cc @@ -124,7 +124,6 @@ bool HttpsMethod::Fetch(FetchItem *Itm) curl_easy_setopt(curl, CURLOPT_PROGRESSFUNCTION, progress_callback); curl_easy_setopt(curl, CURLOPT_PROGRESSDATA, this); curl_easy_setopt(curl, CURLOPT_NOPROGRESS, false); - curl_easy_setopt(curl, CURLOPT_FAILONERROR, true); curl_easy_setopt(curl, CURLOPT_FILETIME, true); // SSL parameters are set by default to the common (non mirror-specific) value @@ -240,6 +239,7 @@ bool HttpsMethod::Fetch(FetchItem *Itm) curl_easy_setopt(curl, CURLOPT_VERBOSE, true); // error handling + curl_errorstr[0] = '\0'; curl_easy_setopt(curl, CURLOPT_ERRORBUFFER, curl_errorstr); // If we ask for uncompressed files servers might respond with content- @@ -288,7 +288,7 @@ bool HttpsMethod::Fetch(FetchItem *Itm) File->Close(); // cleanup - if(success != 0) + if(success != 0 || (curl_responsecode != 200 && curl_responsecode != 304)) { _error->Error("%s", curl_errorstr); // unlink, no need keep 401/404 page content in partial/ diff --git a/methods/https.h b/methods/https.h index b1961a870..293e288e0 100644 --- a/methods/https.h +++ b/methods/https.h @@ -41,6 +41,11 @@ class HttpsMethod : public pkgAcqMethod File = 0; curl = curl_easy_init(); }; + + ~HttpsMethod() + { + curl_easy_cleanup(curl); + }; }; #include <apt-pkg/strutl.h> @@ -9,7 +9,7 @@ msgstr "" "Project-Id-Version: apt 0.9.7.1\n" "Report-Msgid-Bugs-To: APT Development Team <deity@lists.debian.org>\n" "POT-Creation-Date: 2012-10-15 09:49+0200\n" -"PO-Revision-Date: 2012-07-01 00:14+0900\n" +"PO-Revision-Date: 2013-02-05 09:41+0900\n" "Last-Translator: Kenshi Muto <kmuto@debian.org>\n" "Language-Team: Debian Japanese List <debian-japanese@lists.debian.org>\n" "Language: ja\n" @@ -227,7 +227,7 @@ msgstr "" " -p=? パッケージキャッシュ\n" " -s=? ソースキャッシュ\n" " -q プログレス表示をしない\n" -" -i umnet コマンドで重要な依存情報のみを表示する\n" +" -i unmet コマンドで重要な依存情報のみを表示する\n" " -c=? 指定した設定ファイルを読み込む\n" " -o=? 指定した設定オプションを読み込む (例: -o dir::cache=/tmp)\n" "詳細は、apt-cache(8) や apt.conf(5) のマニュアルページを参照してください。\n" @@ -448,8 +448,8 @@ msgstr "'%s' のような仮想パッケージは削除できません\n" #, c-format msgid "Package '%s' is not installed, so not removed. Did you mean '%s'?\n" msgstr "" -"パッケージ %s はインストールされていないため、削除はできません。'%s' のことで" -"しょうか?\n" +"パッケージ '%s' はインストールされていないため、削除はできません。'%s' のこと" +"でしょうか?\n" #: cmdline/apt-get.cc:743 cmdline/apt-get.cc:946 #, c-format @@ -679,7 +679,7 @@ msgstr[0] "" #: cmdline/apt-get.cc:1421 msgid "Note: This is done automatically and on purpose by dpkg." -msgstr "注意: これは dpkg により自動でわざと行われれます。" +msgstr "注意: これは dpkg により自動でわざと行われます。" #: cmdline/apt-get.cc:1559 #, c-format @@ -2726,7 +2726,7 @@ msgstr "" #: apt-pkg/sourcelist.cc:116 #, c-format msgid "Malformed line %lu in source list %s ([%s] has no key)" -msgstr "ソースリスト %2$s の %1$lu 行目が不正です ([%3$s にキーがありません)" +msgstr "ソースリスト %2$s の %1$lu 行目が不正です ([%3$s] にキーがありません)" #: apt-pkg/sourcelist.cc:119 #, c-format |