[axel-commits] r106 - in /branches/2.x: CHANGES Makefile axel.1 axel.c axel.spec configure de.po gui/kapt/axel-kapt http.c nl.po ru.po text.c zh_CN.po zh_cn.po
appaji at users.alioth.debian.org
appaji at users.alioth.debian.org
Mon Apr 27 13:45:53 UTC 2009
Author: appaji
Date: Mon Apr 27 13:45:53 2009
New Revision: 106
URL: http://svn.debian.org/wsvn/axel/?sc=1&rev=106
Log:
Merge from trunk and prepare for 2.4
Added:
branches/2.x/zh_CN.po
- copied, changed from r102, branches/2.x/zh_cn.po
Removed:
branches/2.x/axel.spec
branches/2.x/zh_cn.po
Modified:
branches/2.x/CHANGES
branches/2.x/Makefile
branches/2.x/axel.1
branches/2.x/axel.c
branches/2.x/configure
branches/2.x/de.po
branches/2.x/gui/kapt/axel-kapt
branches/2.x/http.c
branches/2.x/nl.po
branches/2.x/ru.po
branches/2.x/text.c
Modified: branches/2.x/CHANGES
URL: http://svn.debian.org/wsvn/axel/branches/2.x/CHANGES?rev=106&op=diff
==============================================================================
--- branches/2.x/CHANGES (original)
+++ branches/2.x/CHANGES Mon Apr 27 13:45:53 2009
@@ -1,3 +1,12 @@
+Version 2.4
+
+- Fix a buffer overflow caused by wrong size limits when copying strings (Closes: #311569), thanks Michael Schwendt and the Fedora project members
+- Fix thread hangups due to incorrect synchronization (Closes: #311469), thanks Yao Shi
+- Removed Fedora packaging file. axel will be available in the Fedora repositories soon.
+- Use /etc/ instead of /usr/etc/ as the default system-wide configuration location.
+- Respect environment CFLAGS in configure.
+- Allow special characters in arguments to configure.
+
Version 2.3
- Wait for thread termination in axel.c:axel_do (Closes: #311255), thanks John Ripa
Modified: branches/2.x/Makefile
URL: http://svn.debian.org/wsvn/axel/branches/2.x/Makefile?rev=106&op=diff
==============================================================================
--- branches/2.x/Makefile (original)
+++ branches/2.x/Makefile Mon Apr 27 13:45:53 2009
@@ -12,7 +12,7 @@
.SUFFIXES: .po .mo
# Add your translation here..
-MOFILES = nl.mo de.mo ru.mo zh_cn.mo
+MOFILES = nl.mo de.mo ru.mo zh_CN.mo
all: $(OUTFILE)
Modified: branches/2.x/axel.1
URL: http://svn.debian.org/wsvn/axel/branches/2.x/axel.1?rev=106&op=diff
==============================================================================
--- branches/2.x/axel.1 (original)
+++ branches/2.x/axel.1 Mon Apr 27 13:45:53 2009
@@ -129,7 +129,8 @@
.SH FILES
.PP
-\fI/etc/axelrc\fP System-wide configuration file
+\fI/etc/axelrc\fP System-wide configuration file. Note that development versions
+place this file in /usr/local/etc.
.PP
\fI~/.axelrc\fP Personal configuration file
.PP
Modified: branches/2.x/axel.c
URL: http://svn.debian.org/wsvn/axel/branches/2.x/axel.c?rev=106&op=diff
==============================================================================
--- branches/2.x/axel.c (original)
+++ branches/2.x/axel.c Mon Apr 27 13:45:53 2009
@@ -238,8 +238,12 @@
if( axel->conn[i].currentbyte <= axel->conn[i].lastbyte )
{
if( axel->conf->verbose >= 2 )
+ {
axel_message( axel, _("Connection %i downloading from %s:%i using interface %s"),
i, axel->conn[i].host, axel->conn[i].port, axel->conn[i].local_if );
+ }
+
+ axel->conn[i].state = 1;
if( pthread_create( axel->conn[i].setup_thread, NULL, setup_thread, &axel->conn[i] ) != 0 )
{
axel_message( axel, _("pthread error!!!") );
@@ -248,7 +252,6 @@
else
{
axel->conn[i].last_transfer = gettime();
- axel->conn[i].state = 1;
}
}
@@ -397,9 +400,10 @@
if( axel->conf->verbose >= 2 )
axel_message( axel, _("Connection %i downloading from %s:%i using interface %s"),
i, axel->conn[i].host, axel->conn[i].port, axel->conn[i].local_if );
+
+ axel->conn[i].state = 1;
if( pthread_create( axel->conn[i].setup_thread, NULL, setup_thread, &axel->conn[i] ) == 0 )
{
- axel->conn[i].state = 1;
axel->conn[i].last_transfer = gettime();
}
else
Modified: branches/2.x/configure
URL: http://svn.debian.org/wsvn/axel/branches/2.x/configure?rev=106&op=diff
==============================================================================
--- branches/2.x/configure (original)
+++ branches/2.x/configure Mon Apr 27 13:45:53 2009
@@ -12,7 +12,7 @@
mandir='$prefix/share/man'
locale='$prefix/share/locale'
-i18n=0
+i18n=1
debug=0
strip=1
@@ -40,7 +40,11 @@
EOF
exit;
fi
- eval "$e"
+
+ keyname=$(expr "$e" : '\(.*\)=.*' | sed 's/[^a-z0-9_]/_/g')
+ value=$(expr "$e" : '.*=\(.*\)' | sed "s/'/_/g")
+
+ eval "$keyname='$value'"
shift;
done
@@ -49,6 +53,10 @@
etcdir=`eval echo $etcdir`
mandir=`eval echo $mandir`
locale=`eval echo $locale`
+if test "$etcdir" = "/usr/etc"; then
+ # FHS explicitely forbids /usr/etc
+ etcdir='/etc'
+fi
cat<<EOF>Makefile.settings
## Axel settings, generated by configure
@@ -85,8 +93,9 @@
fi;
fi
-echo 'CFLAGS=-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -g -Os' >> Makefile.settings
+echo "CFLAGS=-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Os ${CFLAGS}" >> Makefile.settings
if [ "$debug" = "1" ]; then
+ echo 'CFLAGS+=-g' >> Makefile.settings
echo 'DEBUG=1' >> Makefile.settings
echo '#define DEBUG' >> config.h;
fi
Modified: branches/2.x/de.po
URL: http://svn.debian.org/wsvn/axel/branches/2.x/de.po?rev=106&op=diff
==============================================================================
--- branches/2.x/de.po (original)
+++ branches/2.x/de.po Mon Apr 27 13:45:53 2009
@@ -2,7 +2,7 @@
msgstr ""
"Project-Id-Version: Axel\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-01-05 11:14+0530\n"
+"POT-Creation-Date: 2009-04-27 13:21+0530\n"
"PO-Revision-Date: 2008-09-15 22:08+0200\n"
"Last-Translator: Hermann J. Beckers <hj.beckers at onlinehome.de>\n"
"Language-Team: deutsch <de at li.org>\n"
@@ -50,35 +50,35 @@
msgid "Starting download"
msgstr "Starte Abruf"
-#: axel.c:241 axel.c:398
+#: axel.c:242 axel.c:401
#, c-format
msgid "Connection %i downloading from %s:%i using interface %s"
msgstr "Verbindung %i: Abruf von %s:%i über Schnittstelle %s"
-#: axel.c:245 axel.c:407
+#: axel.c:249 axel.c:411
msgid "pthread error!!!"
msgstr "pthread Fehler!!!"
-#: axel.c:314
+#: axel.c:317
#, c-format
msgid "Error on connection %i! Connection closed"
msgstr "Fehler bei Verbindung %i! Verbindung getrennt"
-#: axel.c:328
+#: axel.c:331
#, c-format
msgid "Connection %i unexpectedly closed"
msgstr "Verbindung %i unerwartet getrennt"
-#: axel.c:332 axel.c:349
+#: axel.c:335 axel.c:352
#, c-format
msgid "Connection %i finished"
msgstr "Verbindung %i beendet"
-#: axel.c:361
+#: axel.c:364
msgid "Write error!"
msgstr "Schreibfehler!"
-#: axel.c:373
+#: axel.c:376
#, c-format
msgid "Connection %i timed out"
msgstr "Time-out bei Verbindung %i"
@@ -143,47 +143,57 @@
msgid "Can't redirect stdout to /dev/null.\n"
msgstr "Kann Standardausgabe nicht nach /dev/null umleiten.\n"
-#: text.c:182
+#: text.c:176
+#, c-format
+msgid "Error when trying to read URL (Too long?).\n"
+msgstr "Fehler beim Lesen der URL (Zu lang?).\n"
+
+#: text.c:185
#, c-format
msgid "Can't handle URLs of length over %d\n"
msgstr "Kann URLs mit mehr als %d Zeichen nicht nutzen\n"
-#: text.c:187
+#: text.c:190
#, c-format
msgid "Initializing download: %s\n"
msgstr "Starte Abruf: %s\n"
-#: text.c:194
+#: text.c:197
#, c-format
msgid "Doing search...\n"
msgstr "Suche gestartet...\n"
-#: text.c:198
+#: text.c:201
#, c-format
msgid "File not found\n"
msgstr "Datei nicht gefunden\n"
-#: text.c:202
+#: text.c:205
#, c-format
msgid "Testing speeds, this can take a while...\n"
msgstr "Teste Geschwindigkeiten, das kann etwas dauern...\n"
-#: text.c:207
+#: text.c:210
#, c-format
msgid "%i usable servers found, will use these URLs:\n"
msgstr "%i benutzbare Server gefunden, werde diese URLs benutzen:\n"
#: text.c:269
#, c-format
+msgid "Filename too long!\n"
+msgstr "Dateiname zu lang!\n"
+
+#: text.c:281
+#, c-format
msgid "No state file, cannot resume!\n"
msgstr "Keine Status-Datei, Fortsetzung nicht möglich!\n"
-#: text.c:274
+#: text.c:286
#, c-format
msgid "State file found, but no downloaded data. Starting from scratch.\n"
msgstr "Status-Datei gefunden, aber noch nichts übertragen. Neustart.\n"
-#: text.c:405
+#: text.c:417
#, c-format
msgid ""
"\n"
@@ -192,47 +202,47 @@
"\n"
"%s abgerufen in %s. (%.2f KB/s)\n"
-#: text.c:427
+#: text.c:439
#, fuzzy, c-format
msgid "%lld byte"
msgstr "%i Byte"
-#: text.c:429
+#: text.c:441
#, fuzzy, c-format
msgid "%lld bytes"
msgstr "%i Bytes"
-#: text.c:431
+#: text.c:443
#, c-format
msgid "%.1f kilobytes"
msgstr "%.1f Kilobytes"
-#: text.c:433
+#: text.c:445
#, c-format
msgid "%.1f megabytes"
msgstr "%.1f Megabytes"
-#: text.c:442
+#: text.c:454
#, c-format
msgid "%i second"
msgstr "%i Sekunde"
-#: text.c:444
+#: text.c:456
#, c-format
msgid "%i seconds"
msgstr "%i Sekunden"
-#: text.c:446
+#: text.c:458
#, c-format
msgid "%i:%02i seconds"
msgstr "%i:%02i Sekunden"
-#: text.c:448
+#: text.c:460
#, c-format
msgid "%i:%02i:%02i seconds"
msgstr "%i:%02i:%02i Sekunden"
-#: text.c:528
+#: text.c:540
#, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -268,7 +278,7 @@
"\n"
"Fehler an lintux at lintux.cx melden.\n"
-#: text.c:545
+#: text.c:557
#, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -294,8 +304,8 @@
"--num-connections=x\t-n x\tmaximale gleichzeitige Verbindungen\n"
"--output=f\t\t-o f\tlokale Ausgabe-Datei\n"
"--search=[x]\t\t-S [x] Suche nach Spiegelservern und Abruf von x Servern\n"
-"--header=x\f\t-H x\tSende HTTP-Header\n"
-"--user-agent=x\f\t-U x\tSetze Browser-Kennung\n"
+"--header=x\t\t-H x\tSende HTTP-Header\n"
+"--user-agent=x\t\t-U x\tSetze Browser-Kennung\n"
"--no-proxy\t\t-N\tkeinen Proxy-Server benutzen\n"
"--quiet\t\t\t-q\tkeine Meldungen auf Standard-Ausgabe\n"
"--verbose\t\t-v\tzusätzliche Status-Information\n"
@@ -304,7 +314,7 @@
"\n"
"Fehler an lintux at lintux.cx melden.\n"
-#: text.c:566
+#: text.c:578
#, c-format
msgid "Axel version %s (%s)\n"
msgstr "Axel Version %s (%s)\n"
Modified: branches/2.x/gui/kapt/axel-kapt
URL: http://svn.debian.org/wsvn/axel/branches/2.x/gui/kapt/axel-kapt?rev=106&op=diff
==============================================================================
--- branches/2.x/gui/kapt/axel-kapt (original)
+++ branches/2.x/gui/kapt/axel-kapt Mon Apr 27 13:45:53 2009
@@ -45,7 +45,7 @@
verb "Verbose" -> @|" --verbose ";
quiet "Quiet" -> @|" -q ";
- term "Terminal Type" -> @combo("konsole", "rxvt", "xterm", "aterm");
+ term "Terminal Type" -> @string()="xterm";
max "Max bps"-> @integer()=0;
connex :horizontal "Connections" -> @integer()=4;
search :framed "ftp Search" -> numsites | ! @ ;
Modified: branches/2.x/http.c
URL: http://svn.debian.org/wsvn/axel/branches/2.x/http.c?rev=106&op=diff
==============================================================================
--- branches/2.x/http.c (original)
+++ branches/2.x/http.c Mon Apr 27 13:45:53 2009
@@ -124,7 +124,7 @@
strcat( s, "\r\n" );
va_end( params );
- strncat( conn->request, s, MAX_QUERY );
+ strncat( conn->request, s, MAX_QUERY - strlen(conn->request) - 1);
}
int http_exec( http_t *conn )
Modified: branches/2.x/nl.po
URL: http://svn.debian.org/wsvn/axel/branches/2.x/nl.po?rev=106&op=diff
==============================================================================
--- branches/2.x/nl.po (original)
+++ branches/2.x/nl.po Mon Apr 27 13:45:53 2009
@@ -2,7 +2,7 @@
msgstr ""
"Project-Id-Version: Axel\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-01-05 11:14+0530\n"
+"POT-Creation-Date: 2009-04-27 13:21+0530\n"
"PO-Revision-Date: 2001-11-14 15:22+0200\n"
"Last-Translator: Wilmer van der Gaast <wilmer at gaast.net>\n"
"Language-Team: Dutch <nl at li.org>\n"
@@ -49,35 +49,35 @@
msgid "Starting download"
msgstr "Begin download"
-#: axel.c:241 axel.c:398
+#: axel.c:242 axel.c:401
#, c-format
msgid "Connection %i downloading from %s:%i using interface %s"
msgstr "Verbinding %i gebruikt server %s:%i via interface %s"
-#: axel.c:245 axel.c:407
+#: axel.c:249 axel.c:411
msgid "pthread error!!!"
msgstr "pthread fout!!!"
-#: axel.c:314
+#: axel.c:317
#, c-format
msgid "Error on connection %i! Connection closed"
msgstr "Fout op verbinding %i! Verbinding gesloten"
-#: axel.c:328
+#: axel.c:331
#, c-format
msgid "Connection %i unexpectedly closed"
msgstr "Verbinding %i onverwachts gesloten"
-#: axel.c:332 axel.c:349
+#: axel.c:335 axel.c:352
#, c-format
msgid "Connection %i finished"
msgstr "Verbinding %i klaar"
-#: axel.c:361
+#: axel.c:364
msgid "Write error!"
msgstr "Schrijffout!"
-#: axel.c:373
+#: axel.c:376
#, c-format
msgid "Connection %i timed out"
msgstr "Time-out op verbinding %i"
@@ -142,47 +142,57 @@
msgid "Can't redirect stdout to /dev/null.\n"
msgstr "Fout bij het afsluiten van stdout.\n"
-#: text.c:182
+#: text.c:176
+#, c-format
+msgid "Error when trying to read URL (Too long?).\n"
+msgstr ""
+
+#: text.c:185
#, c-format
msgid "Can't handle URLs of length over %d\n"
msgstr ""
-#: text.c:187
+#: text.c:190
#, c-format
msgid "Initializing download: %s\n"
msgstr "Begin download: %s\n"
-#: text.c:194
+#: text.c:197
#, c-format
msgid "Doing search...\n"
msgstr "Zoeken...\n"
-#: text.c:198
+#: text.c:201
#, c-format
msgid "File not found\n"
msgstr "Bestand niet gevonden\n"
-#: text.c:202
+#: text.c:205
#, c-format
msgid "Testing speeds, this can take a while...\n"
msgstr "Snelheden testen, dit kan even duren...\n"
-#: text.c:207
+#: text.c:210
#, c-format
msgid "%i usable servers found, will use these URLs:\n"
msgstr "%i bruikbare servers gevonden, de volgende worden gebruikt:\n"
#: text.c:269
#, c-format
+msgid "Filename too long!\n"
+msgstr ""
+
+#: text.c:281
+#, c-format
msgid "No state file, cannot resume!\n"
msgstr "Geen .st bestand, kan niet resumen!\n"
-#: text.c:274
+#: text.c:286
#, c-format
msgid "State file found, but no downloaded data. Starting from scratch.\n"
msgstr ".st bestand gevonden maar geen uitvoerbestand. Opnieuw beginnen.\n"
-#: text.c:405
+#: text.c:417
#, c-format
msgid ""
"\n"
@@ -191,47 +201,47 @@
"\n"
"%s gedownload in %s. (%.2f KB/s)\n"
-#: text.c:427
+#: text.c:439
#, fuzzy, c-format
msgid "%lld byte"
msgstr "%i byte"
-#: text.c:429
+#: text.c:441
#, fuzzy, c-format
msgid "%lld bytes"
msgstr "%i bytes"
-#: text.c:431
+#: text.c:443
#, c-format
msgid "%.1f kilobytes"
msgstr "%.1f kilobytes"
-#: text.c:433
+#: text.c:445
#, c-format
msgid "%.1f megabytes"
msgstr "%.1f megabytes"
-#: text.c:442
+#: text.c:454
#, c-format
msgid "%i second"
msgstr "%i seconde"
-#: text.c:444
+#: text.c:456
#, c-format
msgid "%i seconds"
msgstr "%i seconden"
-#: text.c:446
+#: text.c:458
#, c-format
msgid "%i:%02i seconds"
msgstr "%i:%02i seconden"
-#: text.c:448
+#: text.c:460
#, c-format
msgid "%i:%02i:%02i seconds"
msgstr "%i:%02i:%02i seconden"
-#: text.c:528
+#: text.c:540
#, fuzzy, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -266,7 +276,7 @@
"\n"
"Bugs melden aan lintux at lintux.cx\n"
-#: text.c:545
+#: text.c:557
#, fuzzy, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -301,7 +311,7 @@
"\n"
"Bugs melden aan lintux at lintux.cx\n"
-#: text.c:566
+#: text.c:578
#, c-format
msgid "Axel version %s (%s)\n"
msgstr "Axel versie %s (%s)\n"
Modified: branches/2.x/ru.po
URL: http://svn.debian.org/wsvn/axel/branches/2.x/ru.po?rev=106&op=diff
==============================================================================
--- branches/2.x/ru.po (original)
+++ branches/2.x/ru.po Mon Apr 27 13:45:53 2009
@@ -2,7 +2,7 @@
msgstr ""
"Project-Id-Version: Axel\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-01-05 11:15+0530\n"
+"POT-Creation-Date: 2009-04-27 13:21+0530\n"
"Last-Translator: newhren <colimit at gmail.com>\n"
"Language-Team: Russian <ru at li.org>\n"
"MIME-Version: 1.0\n"
@@ -49,35 +49,35 @@
msgid "Starting download"
msgstr "ÐаÑинаем ÑкаÑивание"
-#: axel.c:241 axel.c:398
+#: axel.c:242 axel.c:401
#, c-format
msgid "Connection %i downloading from %s:%i using interface %s"
msgstr "Соединение %i ÑкаÑÐ¸Ð²Ð°ÐµÑ Ñ %s:%i ÑеÑез инÑеÑÑÐµÐ¹Ñ %s"
-#: axel.c:245 axel.c:407
+#: axel.c:249 axel.c:411
msgid "pthread error!!!"
msgstr "оÑибка pthread!!!"
-#: axel.c:314
+#: axel.c:317
#, c-format
msgid "Error on connection %i! Connection closed"
msgstr "ÐÑибка в Ñоединении %i! Соединение закÑÑÑо"
-#: axel.c:328
+#: axel.c:331
#, c-format
msgid "Connection %i unexpectedly closed"
msgstr "Соединение %i неожиданно закÑÑлоÑÑ"
-#: axel.c:332 axel.c:349
+#: axel.c:335 axel.c:352
#, c-format
msgid "Connection %i finished"
msgstr "Соединение %i законÑилоÑÑ"
-#: axel.c:361
+#: axel.c:364
msgid "Write error!"
msgstr "ÐÑибка запиÑи!"
-#: axel.c:373
+#: axel.c:376
#, c-format
msgid "Connection %i timed out"
msgstr "ÐÑÐµÐ¼Ñ ÑÐ¾ÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ %i вÑÑло"
@@ -142,49 +142,59 @@
msgid "Can't redirect stdout to /dev/null.\n"
msgstr "Ðевозможно пеÑенапÑавиÑÑ stdout в /dev/null.\n"
-#: text.c:182
+#: text.c:176
+#, c-format
+msgid "Error when trying to read URL (Too long?).\n"
+msgstr ""
+
+#: text.c:185
#, c-format
msgid "Can't handle URLs of length over %d\n"
msgstr "URLs длинной болÑÑе %d не поддеÑживаÑÑÑÑ\n"
-#: text.c:187
+#: text.c:190
#, c-format
msgid "Initializing download: %s\n"
msgstr "ÐаÑÐ¸Ð½Ð°Ñ ÑкаÑивание: %s\n"
-#: text.c:194
+#: text.c:197
#, c-format
msgid "Doing search...\n"
msgstr "ÐÑем...\n"
-#: text.c:198
+#: text.c:201
#, c-format
msgid "File not found\n"
msgstr "Файл не найден\n"
-#: text.c:202
+#: text.c:205
#, c-format
msgid "Testing speeds, this can take a while...\n"
msgstr "ÐÑобÑем ÑкоÑоÑÑи, ÑÑо Ð¼Ð¾Ð¶ÐµÑ Ð·Ð°Ð½ÑÑÑ Ð½ÐµÐºÐ¾ÑоÑое вÑемÑ...\n"
-#: text.c:207
+#: text.c:210
#, c-format
msgid "%i usable servers found, will use these URLs:\n"
msgstr "Ðайдено %i полезнÑÑ
ÑеÑвеÑов, бÑдÑÑ Ð¸ÑполÑÐ·Ð¾Ð²Ð°Ð½Ñ ÑледÑÑÑие URLs:\n"
#: text.c:269
#, c-format
+msgid "Filename too long!\n"
+msgstr ""
+
+#: text.c:281
+#, c-format
msgid "No state file, cannot resume!\n"
msgstr "Файл ÑоÑÑоÑÐ½Ð¸Ñ Ð½Ðµ найден, возобновление невозможно!\n"
-#: text.c:274
+#: text.c:286
#, c-format
msgid "State file found, but no downloaded data. Starting from scratch.\n"
msgstr ""
"Файл ÑоÑÑоÑÐ½Ð¸Ñ Ð½Ð°Ð¹Ð´ÐµÐ½, но пÑедваÑиÑелÑно ÑкаÑаннÑе даннÑе оÑÑÑÑÑÑвÑÑÑ. "
"ÐаÑинаем заново.\n"
-#: text.c:405
+#: text.c:417
#, c-format
msgid ""
"\n"
@@ -193,47 +203,47 @@
"\n"
"%s ÑкаÑано за %s. (%.2f ÐÐ/Ñ)\n"
-#: text.c:427
+#: text.c:439
#, c-format
msgid "%lld byte"
msgstr "%lld байÑ"
-#: text.c:429
+#: text.c:441
#, c-format
msgid "%lld bytes"
msgstr "%lld байÑа(ов)"
-#: text.c:431
+#: text.c:443
#, c-format
msgid "%.1f kilobytes"
msgstr "%.1f килобайÑа(ов)"
-#: text.c:433
+#: text.c:445
#, c-format
msgid "%.1f megabytes"
msgstr "%.1f мегабайÑа(ов)"
-#: text.c:442
+#: text.c:454
#, c-format
msgid "%i second"
msgstr "%i ÑекÑнда"
-#: text.c:444
+#: text.c:456
#, c-format
msgid "%i seconds"
msgstr "%i ÑекÑнд(Ñ)"
-#: text.c:446
+#: text.c:458
#, c-format
msgid "%i:%02i seconds"
msgstr "%i:%02i ÑекÑнд(Ñ)"
-#: text.c:448
+#: text.c:460
#, c-format
msgid "%i:%02i:%02i seconds"
msgstr "%i:%02i:%02i ÑекÑнд(Ñ)"
-#: text.c:528
+#: text.c:540
#, fuzzy, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -268,7 +278,7 @@
"\n"
"Ðб оÑибкаÑ
ÑообÑайÑе на http://axel.alioth.debian.org/\n"
-#: text.c:545
+#: text.c:557
#, fuzzy, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -303,7 +313,7 @@
"\n"
"Ðб оÑибкаÑ
ÑообÑайÑе на http://axel.alioth.debian.org/\n"
-#: text.c:566
+#: text.c:578
#, c-format
msgid "Axel version %s (%s)\n"
msgstr "Axel, веÑÑÐ¸Ñ %s (%s)\n"
Modified: branches/2.x/text.c
URL: http://svn.debian.org/wsvn/axel/branches/2.x/text.c?rev=106&op=diff
==============================================================================
--- branches/2.x/text.c (original)
+++ branches/2.x/text.c Mon Apr 27 13:45:53 2009
@@ -172,7 +172,10 @@
else if( strcmp( argv[optind], "-" ) == 0 )
{
s = malloc( MAX_STRING );
- scanf( "%1024[^\n]s", s );
+ if (scanf( "%1024[^\n]s", s) != 1) {
+ fprintf( stderr, _("Error when trying to read URL (Too long?).\n") );
+ return( 1 );
+ }
}
else
{
@@ -259,8 +262,17 @@
{
if( S_ISDIR( buf.st_mode ) )
{
- strncat( fn, "/", MAX_STRING );
- strncat( fn, axel->filename, MAX_STRING );
+ size_t fnlen = strlen(fn);
+ size_t axelfnlen = strlen(axel->filename);
+
+ if (fnlen + 1 + axelfnlen + 1 > MAX_STRING) {
+ fprintf( stderr, _("Filename too long!\n"));
+ return ( 1 );
+ }
+
+ fn[fnlen] = '/';
+ memcpy(fn+fnlen+1, axel->filename, axelfnlen);
+ fn[fnlen + 1 + axelfnlen] = '\0';
}
}
sprintf( string, "%s.st", fn );
Copied: branches/2.x/zh_CN.po (from r102, branches/2.x/zh_cn.po)
URL: http://svn.debian.org/wsvn/axel/branches/2.x/zh_CN.po?rev=106&op=diff
==============================================================================
--- branches/2.x/zh_cn.po (original)
+++ branches/2.x/zh_CN.po Mon Apr 27 13:45:53 2009
@@ -2,7 +2,7 @@
msgstr ""
"Project-Id-Version: Axel\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2009-01-05 11:15+0530\n"
+"POT-Creation-Date: 2009-04-27 13:21+0530\n"
"PO-Revision-Date: 2008-11-08 22:40+0700\n"
"Last-Translator: Shuge Lee <shuge.lee at gmail.com>\n"
"Language-Team: Simplified Chinese <i18n-zh at i18n.org>\n"
@@ -52,35 +52,35 @@
msgid "Starting download"
msgstr "å¼å§ä¸è½½"
-#: axel.c:241 axel.c:398
+#: axel.c:242 axel.c:401
#, c-format
msgid "Connection %i downloading from %s:%i using interface %s"
msgstr "è¿æ¥ %i ä» %s:%i éè¿æ¥å£ %s ä¸è½½"
-#: axel.c:245 axel.c:407
+#: axel.c:249 axel.c:411
msgid "pthread error!!!"
msgstr "线ç¨é误ï¼ï¼ï¼"
-#: axel.c:314
+#: axel.c:317
#, c-format
msgid "Error on connection %i! Connection closed"
msgstr "è¿æ¥ %i æéè¯¯ï¼ è¿æ¥ä¸æ"
-#: axel.c:328
+#: axel.c:331
#, c-format
msgid "Connection %i unexpectedly closed"
msgstr "è¿æ¥ %i 被å¼å¸¸ä¸æ"
-#: axel.c:332 axel.c:349
+#: axel.c:335 axel.c:352
#, c-format
msgid "Connection %i finished"
msgstr "è¿æ¥ %i ç»æ"
-#: axel.c:361
+#: axel.c:364
msgid "Write error!"
msgstr "åé误ï¼"
-#: axel.c:373
+#: axel.c:376
#, c-format
msgid "Connection %i timed out"
msgstr "è¿æ¥è¶
æ¶ %i"
@@ -145,47 +145,57 @@
msgid "Can't redirect stdout to /dev/null.\n"
msgstr "stdout ä¸è½éå®åå° /dev/null ã\n"
-#: text.c:182
+#: text.c:176
+#, c-format
+msgid "Error when trying to read URL (Too long?).\n"
+msgstr ""
+
+#: text.c:185
#, c-format
msgid "Can't handle URLs of length over %d\n"
msgstr "ä¸è½å¤çé¿åº¦è¶
è¿ %d çURLs\n"
-#: text.c:187
+#: text.c:190
#, c-format
msgid "Initializing download: %s\n"
msgstr "åå§åä¸è½½: %s\n"
-#: text.c:194
+#: text.c:197
#, c-format
msgid "Doing search...\n"
msgstr "è¿è¡æç´¢ä¸...\n"
-#: text.c:198
+#: text.c:201
#, c-format
msgid "File not found\n"
msgstr "æä»¶æ¾ä¸å°\n"
-#: text.c:202
+#: text.c:205
#, c-format
msgid "Testing speeds, this can take a while...\n"
msgstr "cæµè¯é度ï¼è¿å¯è½æç¹è´¹æ¶â¦â¦\n"
-#: text.c:207
+#: text.c:210
#, c-format
msgid "%i usable servers found, will use these URLs:\n"
msgstr "%i å¯ç¨çæå¡å¨æ²¡ææ¾å°ï¼å°ä½¿ç¨è¿äº URLs ï¼\n"
#: text.c:269
#, c-format
+msgid "Filename too long!\n"
+msgstr ""
+
+#: text.c:281
+#, c-format
msgid "No state file, cannot resume!\n"
msgstr "没æç¶ææä»¶ï¼æ æ³æ¢å¤ï¼\n"
-#: text.c:274
+#: text.c:286
#, c-format
msgid "State file found, but no downloaded data. Starting from scratch.\n"
msgstr "æ¾å°ç¶ææä»¶ï¼ä½æ²¡æå·²ä¸è½½æ°æ®ãéæ°å¼å§ã\n"
-#: text.c:405
+#: text.c:417
#, c-format
msgid ""
"\n"
@@ -194,47 +204,47 @@
"\n"
"%s å·²ä¸è½½ï¼ç¨æ¶ %sãï¼%.2f ååè/ç§ï¼\n"
-#: text.c:427
+#: text.c:439
#, fuzzy, c-format
msgid "%lld byte"
msgstr "%i åè"
-#: text.c:429
+#: text.c:441
#, fuzzy, c-format
msgid "%lld bytes"
msgstr "%i åè"
-#: text.c:431
+#: text.c:443
#, c-format
msgid "%.1f kilobytes"
msgstr "%.1f ååè"
-#: text.c:433
+#: text.c:445
#, c-format
msgid "%.1f megabytes"
msgstr "%.1f å
åè"
-#: text.c:442
+#: text.c:454
#, c-format
msgid "%i second"
msgstr "%i ç§"
-#: text.c:444
+#: text.c:456
#, c-format
msgid "%i seconds"
msgstr "%i ç§"
-#: text.c:446
+#: text.c:458
#, c-format
msgid "%i:%02i seconds"
msgstr "%i:%02i ç§"
-#: text.c:448
+#: text.c:460
#, c-format
msgid "%i:%02i:%02i seconds"
msgstr "%i:%02i:%02i ç§"
-#: text.c:528
+#: text.c:540
#, fuzzy, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -270,7 +280,7 @@
"请å shuge.lee at gmail.com æäº¤ç¿»è¯é误ï¼è¯·å http://axel.alioth.debian.org/ æ"
"交ç¨åºæ¼æ´\n"
-#: text.c:545
+#: text.c:557
#, fuzzy, c-format
msgid ""
"Usage: axel [options] url1 [url2] [url...]\n"
@@ -306,7 +316,7 @@
"请å shuge.lee at gmail.com æäº¤ç¿»è¯é误ï¼è¯·å http://axel.alioth.debian.org/ æ"
"交ç¨åºæ¼æ´\n"
-#: text.c:566
+#: text.c:578
#, c-format
msgid "Axel version %s (%s)\n"
msgstr "Axel çæ¬ %s (%s)\n"
More information about the axel-commits
mailing list