mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
Change all quotes in strings and comments to the new GNU standard.
The asymmetric quotes used by GNU in the past (`...') don't render nicely on modern systems. We now use two \x27 characters ('...'). The proper solution would be to use the correct Unicode symmetric quotes here. However this has the disadvantage that the system requires Unicode support. We don't want that today. If Unicode is available a generated po file can be used to output proper quotes. A simple sed script like the one used for en@quote is sufficient to change them. The changes have been done by applying sed -i "s/\`\([^'\`]*\)'/'\1'/g" to most files and fixing obvious problems by hand. The msgid strings in the po files were fixed with a similar command.
This commit is contained in:
parent
fc00d3fcb2
commit
096e7457ec
175 changed files with 4857 additions and 4869 deletions
|
@ -150,7 +150,7 @@ main(int argc,char *argv[])
|
|||
output=fopen(optarg,"wb");
|
||||
if(output==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open output file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open output file '%s': %s\n",
|
||||
optarg,strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
@ -163,7 +163,7 @@ main(int argc,char *argv[])
|
|||
input=fopen(argv[optind],"r");
|
||||
if(input==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open input file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open input file '%s': %s\n",
|
||||
argv[optind],strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
@ -281,7 +281,7 @@ main(int argc,char *argv[])
|
|||
|
||||
if(curldata->protocols[i]==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: protocol `%s' not supported\n",opt->scheme);
|
||||
fprintf(console,"gpgkeys: protocol '%s' not supported\n",opt->scheme);
|
||||
ret=KEYSERVER_SCHEME_NOT_FOUND;
|
||||
goto fail;
|
||||
}
|
||||
|
|
|
@ -79,19 +79,19 @@ connect_server (const char *server, unsigned short port)
|
|||
|
||||
/* Win32 gethostbyname doesn't handle IP addresses internally, so we
|
||||
try inet_addr first on that platform only. */
|
||||
if ((l = inet_addr (server)) != INADDR_NONE)
|
||||
if ((l = inet_addr (server)) != INADDR_NONE)
|
||||
memcpy (&addr.sin_addr, &l, sizeof l);
|
||||
else if ((hp = gethostbyname (server)))
|
||||
else if ((hp = gethostbyname (server)))
|
||||
{
|
||||
if (hp->h_addrtype != AF_INET)
|
||||
{
|
||||
fprintf (console, "gpgkeys: unknown address family for `%s'\n",
|
||||
fprintf (console, "gpgkeys: unknown address family for '%s'\n",
|
||||
server);
|
||||
return -1;
|
||||
}
|
||||
if (hp->h_length != 4)
|
||||
{
|
||||
fprintf (console, "gpgkeys: illegal address length for `%s'\n",
|
||||
fprintf (console, "gpgkeys: illegal address length for '%s'\n",
|
||||
server);
|
||||
return -1;
|
||||
}
|
||||
|
@ -99,7 +99,7 @@ connect_server (const char *server, unsigned short port)
|
|||
}
|
||||
else
|
||||
{
|
||||
fprintf (console, "gpgkeys: host `%s' not found: ec=%d\n",
|
||||
fprintf (console, "gpgkeys: host '%s' not found: ec=%d\n",
|
||||
server, (int)WSAGetLastError ());
|
||||
return -1;
|
||||
}
|
||||
|
@ -107,14 +107,14 @@ connect_server (const char *server, unsigned short port)
|
|||
sock = socket (AF_INET, SOCK_STREAM, 0);
|
||||
if (sock == INVALID_SOCKET)
|
||||
{
|
||||
fprintf (console, "gpgkeys: error creating socket: ec=%d\n",
|
||||
fprintf (console, "gpgkeys: error creating socket: ec=%d\n",
|
||||
(int)WSAGetLastError ());
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (connect (sock, (struct sockaddr *)&addr, sizeof addr))
|
||||
{
|
||||
fprintf (console, "gpgkeys: error connecting `%s': ec=%d\n",
|
||||
fprintf (console, "gpgkeys: error connecting '%s': ec=%d\n",
|
||||
server, (int)WSAGetLastError ());
|
||||
sock_close (sock);
|
||||
return -1;
|
||||
|
@ -130,30 +130,30 @@ connect_server (const char *server, unsigned short port)
|
|||
host = gethostbyname ((char*)server);
|
||||
if (!host)
|
||||
{
|
||||
fprintf (console, "gpgkeys: host `%s' not found: %s\n",
|
||||
fprintf (console, "gpgkeys: host '%s' not found: %s\n",
|
||||
server, strerror (errno));
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
addr.sin_addr = *(struct in_addr*)host->h_addr;
|
||||
|
||||
sock = socket (AF_INET, SOCK_STREAM, 0);
|
||||
if (sock == -1)
|
||||
{
|
||||
fprintf (console, "gpgkeys: error creating socket: %s\n",
|
||||
fprintf (console, "gpgkeys: error creating socket: %s\n",
|
||||
strerror (errno));
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
if (connect (sock, (struct sockaddr *)&addr, sizeof addr) == -1)
|
||||
{
|
||||
fprintf (console, "gpgkeys: error connecting `%s': %s\n",
|
||||
fprintf (console, "gpgkeys: error connecting '%s': %s\n",
|
||||
server, strerror (errno));
|
||||
close (sock);
|
||||
return -1;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
return sock;
|
||||
}
|
||||
|
||||
|
@ -163,11 +163,11 @@ write_server (int sock, const char *data, size_t length)
|
|||
int nleft;
|
||||
|
||||
nleft = length;
|
||||
while (nleft > 0)
|
||||
while (nleft > 0)
|
||||
{
|
||||
int nwritten;
|
||||
|
||||
#ifdef HAVE_W32_SYSTEM
|
||||
|
||||
#ifdef HAVE_W32_SYSTEM
|
||||
nwritten = send (sock, data, nleft, 0);
|
||||
if ( nwritten == SOCKET_ERROR )
|
||||
{
|
||||
|
@ -184,7 +184,7 @@ write_server (int sock, const char *data, size_t length)
|
|||
if (errno == EAGAIN)
|
||||
{
|
||||
struct timeval tv;
|
||||
|
||||
|
||||
tv.tv_sec = 0;
|
||||
tv.tv_usec = 50000;
|
||||
select(0, NULL, NULL, NULL, &tv);
|
||||
|
@ -197,7 +197,7 @@ write_server (int sock, const char *data, size_t length)
|
|||
nleft -=nwritten;
|
||||
data += nwritten;
|
||||
}
|
||||
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -227,7 +227,7 @@ send_request (const char *request, int *r_sock)
|
|||
return KEYSERVER_GENERAL_ERROR;
|
||||
}
|
||||
*server++ = 0;
|
||||
|
||||
|
||||
sock = connect_server (server, 79);
|
||||
if (sock == -1)
|
||||
{
|
||||
|
@ -272,7 +272,7 @@ get_key (char *getkey)
|
|||
sock_close (sock);
|
||||
return KEYSERVER_OK;
|
||||
}
|
||||
|
||||
|
||||
/* Hmmm, we use iobuf here only to cope with Windows socket
|
||||
peculiarities (we can't used fdopen). */
|
||||
fp_read = iobuf_sockopen (sock , "r");
|
||||
|
@ -286,7 +286,7 @@ get_key (char *getkey)
|
|||
while ( iobuf_read_line ( fp_read, &line, &buflen, &maxlen))
|
||||
{
|
||||
maxlen=1024;
|
||||
|
||||
|
||||
if(gotit)
|
||||
{
|
||||
print_nocr(output, (const char*)line);
|
||||
|
@ -299,7 +299,7 @@ get_key (char *getkey)
|
|||
gotit=1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if(gotit)
|
||||
fprintf (output,"KEY 0x%s END\n", getkey);
|
||||
else
|
||||
|
@ -316,7 +316,7 @@ get_key (char *getkey)
|
|||
}
|
||||
|
||||
|
||||
static void
|
||||
static void
|
||||
show_help (FILE *fp)
|
||||
{
|
||||
fprintf (fp,"-h, --help\thelp\n");
|
||||
|
@ -362,7 +362,7 @@ main(int argc,char *argv[])
|
|||
output=fopen(optarg,"w");
|
||||
if(output==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open output file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open output file '%s': %s\n",
|
||||
optarg,strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
@ -375,7 +375,7 @@ main(int argc,char *argv[])
|
|||
input=fopen(argv[optind],"r");
|
||||
if(input==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open input file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open input file '%s': %s\n",
|
||||
argv[optind],strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
|
|
@ -208,7 +208,7 @@ send_key(int *r_eof)
|
|||
append_path(request,"/pks/add");
|
||||
|
||||
if(opt->verbose>2)
|
||||
fprintf(console,"gpgkeys: HTTP URL is `%s'\n",request);
|
||||
fprintf(console,"gpgkeys: HTTP URL is '%s'\n",request);
|
||||
|
||||
curl_easy_setopt(curl,CURLOPT_URL,request);
|
||||
curl_easy_setopt(curl,CURLOPT_POST,1L);
|
||||
|
@ -289,7 +289,7 @@ get_key(char *getkey)
|
|||
strcat(request,offset);
|
||||
|
||||
if(opt->verbose>2)
|
||||
fprintf(console,"gpgkeys: HTTP URL is `%s'\n",request);
|
||||
fprintf(console,"gpgkeys: HTTP URL is '%s'\n",request);
|
||||
|
||||
curl_easy_setopt(curl,CURLOPT_URL,request);
|
||||
curl_easy_setopt(curl,CURLOPT_WRITEFUNCTION,curl_writer);
|
||||
|
@ -358,7 +358,7 @@ get_name(const char *getkey)
|
|||
fprintf(output,"NAME %s BEGIN\n",getkey);
|
||||
|
||||
if(opt->verbose>2)
|
||||
fprintf(console,"gpgkeys: HTTP URL is `%s'\n",request);
|
||||
fprintf(console,"gpgkeys: HTTP URL is '%s'\n",request);
|
||||
|
||||
curl_easy_setopt(curl,CURLOPT_URL,request);
|
||||
curl_easy_setopt(curl,CURLOPT_WRITEFUNCTION,curl_writer);
|
||||
|
@ -446,7 +446,7 @@ search_key(const char *searchkey)
|
|||
fprintf(output,"SEARCH %s BEGIN\n",searchkey);
|
||||
|
||||
if(opt->verbose>2)
|
||||
fprintf(console,"gpgkeys: HTTP URL is `%s'\n",request);
|
||||
fprintf(console,"gpgkeys: HTTP URL is '%s'\n",request);
|
||||
|
||||
curl_easy_setopt(curl,CURLOPT_URL,request);
|
||||
curl_easy_setopt(curl,CURLOPT_WRITEFUNCTION,curl_mrindex_writer);
|
||||
|
@ -596,7 +596,7 @@ main(int argc,char *argv[])
|
|||
output=fopen(optarg,"w");
|
||||
if(output==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open output file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open output file '%s': %s\n",
|
||||
optarg,strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
@ -609,7 +609,7 @@ main(int argc,char *argv[])
|
|||
input=fopen(argv[optind],"r");
|
||||
if(input==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open input file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open input file '%s': %s\n",
|
||||
argv[optind],strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ get_key (adns_state adns_ctx, char *address)
|
|||
domain = strrchr (address, '@');
|
||||
if (!domain || domain == address || !domain[1])
|
||||
{
|
||||
fprintf (console, PGM": invalid mail address `%s'\n", address);
|
||||
fprintf (console, PGM": invalid mail address '%s'\n", address);
|
||||
ret = KEYSERVER_GENERAL_ERROR;
|
||||
goto leave;
|
||||
}
|
||||
|
@ -105,7 +105,7 @@ get_key (adns_state adns_ctx, char *address)
|
|||
|
||||
fprintf (output,"NAME %s BEGIN\n", address);
|
||||
if (opt->verbose > 2)
|
||||
fprintf(console, PGM": looking up `%s'\n", name);
|
||||
fprintf(console, PGM": looking up '%s'\n", name);
|
||||
|
||||
if ( adns_synchronous (adns_ctx, name, (adns_r_unknown | my_adns_r_cert),
|
||||
adns_qf_quoteok_query|(kdns_usevc?adns_qf_usevc:0),
|
||||
|
@ -254,7 +254,7 @@ main (int argc, char *argv[])
|
|||
output = fopen (optarg,"w");
|
||||
if (!output)
|
||||
{
|
||||
fprintf (console, PGM": cannot open output file `%s': %s\n",
|
||||
fprintf (console, PGM": cannot open output file '%s': %s\n",
|
||||
optarg, strerror(errno) );
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
@ -272,7 +272,7 @@ main (int argc, char *argv[])
|
|||
input = fopen (argv[optind], "r");
|
||||
if (!input)
|
||||
{
|
||||
fprintf (console, PGM": cannot open input file `%s': %s\n",
|
||||
fprintf (console, PGM": cannot open input file '%s': %s\n",
|
||||
argv[optind], strerror(errno) );
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
|
|
@ -1819,7 +1819,7 @@ main(int argc,char *argv[])
|
|||
output=fopen(optarg,"w");
|
||||
if(output==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open output file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open output file '%s': %s\n",
|
||||
optarg,strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
@ -1832,7 +1832,7 @@ main(int argc,char *argv[])
|
|||
input=fopen(argv[optind],"r");
|
||||
if(input==NULL)
|
||||
{
|
||||
fprintf(console,"gpgkeys: Cannot open input file `%s': %s\n",
|
||||
fprintf(console,"gpgkeys: Cannot open input file '%s': %s\n",
|
||||
argv[optind],strerror(errno));
|
||||
return KEYSERVER_INTERNAL_ERROR;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue