summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2011-08-08 17:05:25 -0500
committerDan McGee <dan@archlinux.org>2011-08-08 17:05:25 -0500
commit8fa330335f9eb465724ed778464502f844e930ae (patch)
tree2161500fbdc1ca52f0e1bf15c9f0ab90737d5d01
parentef4757afa5d31ff6a6c09e3410c889f152826f4f (diff)
parent67445334e71eaf6138561eee8e5561733a59fc69 (diff)
downloadpacman-8fa330335f9eb465724ed778464502f844e930ae.tar.xz
Merge branch 'maint'
Conflicts: lib/libalpm/dload.c lib/libalpm/po/fi.po lib/libalpm/po/libalpm.pot po/de.po po/fi.po src/pacman/po/pacman.pot src/pacman/util.c
-rw-r--r--doc/PKGBUILD.5.txt3
-rw-r--r--lib/libalpm/po/fi.po17
-rw-r--r--lib/libalpm/po/libalpm.pot2
-rw-r--r--scripts/po/de.po2
-rw-r--r--src/pacman/po/de.po2
-rw-r--r--src/pacman/po/fi.po2
-rw-r--r--src/pacman/po/pacman.pot2
-rw-r--r--src/pacman/sync.c11
-rw-r--r--src/pacman/util.c38
9 files changed, 62 insertions, 17 deletions
diff --git a/doc/PKGBUILD.5.txt b/doc/PKGBUILD.5.txt
index 393a2f2a..af3a3880 100644
--- a/doc/PKGBUILD.5.txt
+++ b/doc/PKGBUILD.5.txt
@@ -401,8 +401,7 @@ from (e.g., 'makepkg-git', 'mplayer-svn').
The SVN module to fetch.
*Git*::
- The generated pkgver will be one formatted by the 'git-describe'
- command, with '-' characters converted to '_' characters.
+ The generated pkgver will be the date the package is built.
*_gitroot*;;
The URL (all protocols supported) to the GIT repository.
diff --git a/lib/libalpm/po/fi.po b/lib/libalpm/po/fi.po
index 01f2ea5a..8af1205a 100644
--- a/lib/libalpm/po/fi.po
+++ b/lib/libalpm/po/fi.po
@@ -1,16 +1,21 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR Pacman Development Team <pacman-dev@archlinux.org>
# This file is distributed under the same license as the PACKAGE package.
-# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
+# <larso@gmx.com>, 2011.
+# Larso <larso@gmx.com>, 2011.
+# Jesse Jaara <jesse.jaara@gmail.com>, 2011.
+# apuasi <kaannokset.hellberg@gmail.com>, 2011.
+# Dan McGee <dpmcgee@gmail.com>, 2011.
msgid ""
msgstr ""
"Project-Id-Version: Arch Linux Pacman package manager\n"
"Report-Msgid-Bugs-To: http://bugs.archlinux.org/index.php?project=3\n"
-"POT-Creation-Date: 2011-06-23 21:48-0500\n"
-"PO-Revision-Date: 2011-04-18 11:10+0000\n"
-"Last-Translator: apuasi <kaannokset.hellberg@gmail.com>\n"
-"Language-Team: Finnish <None>\n"
+"POT-Creation-Date: 2011-08-08 16:37-0500\n"
+"PO-Revision-Date: 2011-07-28 22:14+0000\n"
+"Last-Translator: Larso <larso@gmx.com>\n"
+"Language-Team: Finnish (http://www.transifex.net/projects/p/archlinux-pacman/"
+"team/fi/)\n"
"Language: fi\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -319,7 +324,7 @@ msgstr "toimenpidettä ei ole alustettu"
#, c-format
msgid "duplicate target"
-msgstr ""
+msgstr "kohde on useampaan kertaan"
#, c-format
msgid "transaction not prepared"
diff --git a/lib/libalpm/po/libalpm.pot b/lib/libalpm/po/libalpm.pot
index 3e41eac2..1f7d25a7 100644
--- a/lib/libalpm/po/libalpm.pot
+++ b/lib/libalpm/po/libalpm.pot
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: pacman 3.5.3\n"
"Report-Msgid-Bugs-To: http://bugs.archlinux.org/index.php?project=3\n"
-"POT-Creation-Date: 2011-06-23 21:48-0500\n"
+"POT-Creation-Date: 2011-08-08 16:37-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
diff --git a/scripts/po/de.po b/scripts/po/de.po
index d09c4b81..f78c7e32 100644
--- a/scripts/po/de.po
+++ b/scripts/po/de.po
@@ -379,7 +379,7 @@ msgid ""
" --holdver Prevent automatic version bumping for development %ss"
msgstr ""
" --holdver Verhindert die automatische Erhöhung der Versionsnummer "
-"für die Entwickler-Vesrion %ss"
+"für die Entwickler-Version %ss"
msgid ""
" --key <key> Specify a key to use for gpg signing instead of the "
diff --git a/src/pacman/po/de.po b/src/pacman/po/de.po
index f2279bc7..78bf77b6 100644
--- a/src/pacman/po/de.po
+++ b/src/pacman/po/de.po
@@ -276,7 +276,7 @@ msgstr ""
#, c-format
msgid "%s: install reason has been set to 'explicitly installed'\n"
msgstr ""
-"%s: Installations-Grund wurde auf \"Ausdrücklich installiert\" gesetzt?\n"
+"%s: Installations-Grund wurde auf \"Ausdrücklich installiert\" gesetzt\n"
#, c-format
msgid "Explicitly installed"
diff --git a/src/pacman/po/fi.po b/src/pacman/po/fi.po
index 0b0c511a..d4da37c0 100644
--- a/src/pacman/po/fi.po
+++ b/src/pacman/po/fi.po
@@ -851,7 +851,7 @@ msgstr "Säilytettävät paketit:\n"
#, c-format
msgid " All locally installed packages\n"
-msgstr " Kaikki paikalliset paketit\n"
+msgstr " Kaikki asennetut paketit\n"
#, c-format
msgid " All current sync database packages\n"
diff --git a/src/pacman/po/pacman.pot b/src/pacman/po/pacman.pot
index 2917e00f..bb50f332 100644
--- a/src/pacman/po/pacman.pot
+++ b/src/pacman/po/pacman.pot
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: pacman 3.5.3\n"
"Report-Msgid-Bugs-To: http://bugs.archlinux.org/index.php?project=3\n"
-"POT-Creation-Date: 2011-06-23 21:59-0500\n"
+"POT-Creation-Date: 2011-08-08 16:32-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
diff --git a/src/pacman/sync.c b/src/pacman/sync.c
index 42a99020..3846b303 100644
--- a/src/pacman/sync.c
+++ b/src/pacman/sync.c
@@ -628,7 +628,15 @@ static int process_group(alpm_list_t *dbs, const char *group)
group);
select_display(pkgs);
char *array = malloc(count);
- multiselect_question(array, count);
+ if(!array) {
+ ret = 1;
+ goto cleanup;
+ }
+ if(multiselect_question(array, count)) {
+ ret = 1;
+ free(array);
+ goto cleanup;
+ }
int n = 0;
for(i = pkgs; i; i = alpm_list_next(i)) {
if(array[n++] == 0)
@@ -641,6 +649,7 @@ static int process_group(alpm_list_t *dbs, const char *group)
goto cleanup;
}
}
+ free(array);
} else {
for(i = pkgs; i; i = alpm_list_next(i)) {
alpm_pkg_t *pkg = alpm_list_getdata(i);
diff --git a/src/pacman/util.c b/src/pacman/util.c
index 8765da7f..e8c0a299 100644
--- a/src/pacman/util.c
+++ b/src/pacman/util.c
@@ -1134,8 +1134,9 @@ static int multiselect_parse(char *array, int count, char *response)
int multiselect_question(char *array, int count)
{
- char response[64];
+ char *response, *lastchar;
FILE *stream;
+ size_t response_len = 64;
if(config->noconfirm) {
stream = stdout;
@@ -1144,12 +1145,21 @@ int multiselect_question(char *array, int count)
stream = stderr;
}
+ response = malloc(response_len);
+ if(!response) {
+ return -1;
+ }
+ lastchar = response + response_len - 1;
+ /* sentinel byte to later see if we filled up the entire string */
+ *lastchar = 1;
+
while(1) {
memset(array, 1, count);
fprintf(stream, "\n");
fprintf(stream, _("Enter a selection (default=all)"));
fprintf(stream, ": ");
+ fflush(stream);
if(config->noconfirm) {
fprintf(stream, "\n");
@@ -1158,7 +1168,24 @@ int multiselect_question(char *array, int count)
flush_term_input();
- if(fgets(response, sizeof(response), stdin)) {
+ if(fgets(response, response_len, stdin)) {
+ const size_t response_incr = 64;
+ /* handle buffer not being large enough to read full line case */
+ while(*lastchar == '\0' && lastchar[-1] != '\n') {
+ response_len += response_incr;
+ response = realloc(response, response_len);
+ if(!response) {
+ return -1;
+ }
+ lastchar = response + response_len - 1;
+ /* sentinel byte */
+ *lastchar = 1;
+ if(fgets(response + response_len - response_incr - 1,
+ response_incr + 1, stdin) == 0) {
+ free(response);
+ return -1;
+ }
+ }
strtrim(response);
if(strlen(response) > 0) {
if(multiselect_parse(array, count, response) == -1) {
@@ -1166,9 +1193,14 @@ int multiselect_question(char *array, int count)
continue;
}
}
+ break;
+ } else {
+ free(response);
+ return -1;
}
- break;
}
+
+ free(response);
return 0;
}