apt/apt-0.5.15cnc5-alt-methods_gpg_homedir.patch
Dmitry V. Levin 0501f88ac1 0.5.15cnc5-alt1
- Specfile cleanup.
- Rediffed patches.
- Fixed --help/--version segfault.
- Fixed some compilation warnings.
- Relocated methods to /usr/lib/apt/methods/.
2004-01-16 19:01:26 +00:00

35 lines
1.2 KiB
Diff

diff -uprk.orig apt-0.5.15cnc5.orig/methods/gpg.cc apt-0.5.15cnc5/methods/gpg.cc
--- apt-0.5.15cnc5.orig/methods/gpg.cc 2003-12-23 23:24:04 +0300
+++ apt-0.5.15cnc5/methods/gpg.cc 2004-01-16 15:23:02 +0300
@@ -196,7 +196,7 @@ char *getFileSigner(const char *file, co
else if (pid == 0)
{
string path = _config->Find("Dir::Bin::gpg", "/usr/bin/gpg");
- string pubring = "";
+ string homedir = "";
const char *argv[16];
int argc = 0;
@@ -207,17 +207,16 @@ char *getFileSigner(const char *file, co
dup2(fd[1], STDERR_FILENO);
unsetenv("LANG");
+ unsetenv("LANGUAGE");
unsetenv("LC_ALL");
unsetenv("LC_MESSAGES");
+ unsetenv("LC_CTYPE");
argv[argc++] = "gpg";
argv[argc++] = "--batch";
argv[argc++] = "--no-secmem-warning";
- pubring = _config->Find("APT::GPG::Pubring");
- if (pubring.empty() == false)
- {
- argv[argc++] = "--keyring"; argv[argc++] = pubring.c_str();
- }
+ homedir = _config->Find("APT::GPG::Homedir", "/usr/lib/alt-gpgkeys");
+ argv[argc++] = "--homedir"; argv[argc++] = homedir.c_str();
argv[argc++] = "--status-fd"; argv[argc++] = "2";
if (outfile != NULL)