1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-06-15 00:29:49 +02:00

Remove trailing white space from some files

--
This commit is contained in:
Werner Koch 2012-12-19 14:05:56 +01:00
parent 550983f8fb
commit 3d56d486e1
3 changed files with 24 additions and 24 deletions

View File

@ -151,7 +151,7 @@ mk_notation_policy_etc( PKT_signature *sig,
/* /*
* Helper to hash a user ID packet. * Helper to hash a user ID packet.
*/ */
static void static void
hash_uid (MD_HANDLE md, int sigversion, const PKT_user_id *uid) hash_uid (MD_HANDLE md, int sigversion, const PKT_user_id *uid)
@ -189,7 +189,7 @@ hash_uid (MD_HANDLE md, int sigversion, const PKT_user_id *uid)
static void static void
hash_sigversion_to_magic (MD_HANDLE md, const PKT_signature *sig) hash_sigversion_to_magic (MD_HANDLE md, const PKT_signature *sig)
{ {
if (sig->version >= 4) if (sig->version >= 4)
md_putc (md, sig->version); md_putc (md, sig->version);
md_putc (md, sig->sig_class); md_putc (md, sig->sig_class);
if (sig->version < 4) { if (sig->version < 4) {
@ -202,7 +202,7 @@ hash_sigversion_to_magic (MD_HANDLE md, const PKT_signature *sig)
else { else {
byte buf[6]; byte buf[6];
size_t n; size_t n;
md_putc (md, sig->pubkey_algo); md_putc (md, sig->pubkey_algo);
md_putc (md, sig->digest_algo); md_putc (md, sig->digest_algo);
if (sig->hashed) { if (sig->hashed) {
@ -258,13 +258,13 @@ do_sign( PKT_secret_key *sk, PKT_signature *sig,
sig->digest_algo = digest_algo; sig->digest_algo = digest_algo;
sig->digest_start[0] = dp[0]; sig->digest_start[0] = dp[0];
sig->digest_start[1] = dp[1]; sig->digest_start[1] = dp[1];
if (sk->is_protected && sk->protect.s2k.mode == 1002) if (sk->is_protected && sk->protect.s2k.mode == 1002)
{ {
#ifdef ENABLE_CARD_SUPPORT #ifdef ENABLE_CARD_SUPPORT
unsigned char *rbuf; unsigned char *rbuf;
size_t rbuflen; size_t rbuflen;
char *snbuf; char *snbuf;
snbuf = serialno_and_fpr_from_sk (sk->protect.iv, snbuf = serialno_and_fpr_from_sk (sk->protect.iv,
sk->protect.ivlen, sk); sk->protect.ivlen, sk);
rc = agent_scd_pksign (snbuf, digest_algo, rc = agent_scd_pksign (snbuf, digest_algo,
@ -282,7 +282,7 @@ do_sign( PKT_secret_key *sk, PKT_signature *sig,
return G10ERR_UNSUPPORTED; return G10ERR_UNSUPPORTED;
#endif /* ENABLE_CARD_SUPPORT */ #endif /* ENABLE_CARD_SUPPORT */
} }
else else
{ {
frame = encode_md_value( NULL, sk, md, digest_algo ); frame = encode_md_value( NULL, sk, md, digest_algo );
if (!frame) if (!frame)
@ -492,7 +492,7 @@ print_status_sig_created ( PKT_secret_key *sk, PKT_signature *sig, int what )
* Loop over the secret certificates in SK_LIST and build the one pass * Loop over the secret certificates in SK_LIST and build the one pass
* signature packets. OpenPGP says that the data should be bracket by * signature packets. OpenPGP says that the data should be bracket by
* the onepass-sig and signature-packet; so we build these onepass * the onepass-sig and signature-packet; so we build these onepass
* packet here in reverse order * packet here in reverse order
*/ */
static int static int
write_onepass_sig_packets (SK_LIST sk_list, IOBUF out, int sigclass ) write_onepass_sig_packets (SK_LIST sk_list, IOBUF out, int sigclass )
@ -508,7 +508,7 @@ write_onepass_sig_packets (SK_LIST sk_list, IOBUF out, int sigclass )
PKT_onepass_sig *ops; PKT_onepass_sig *ops;
PACKET pkt; PACKET pkt;
int i, rc; int i, rc;
for (i=0, sk_rover = sk_list; sk_rover; sk_rover = sk_rover->next ) { for (i=0, sk_rover = sk_list; sk_rover; sk_rover = sk_rover->next ) {
if (++i == skcount) if (++i == skcount)
break; break;
@ -521,7 +521,7 @@ write_onepass_sig_packets (SK_LIST sk_list, IOBUF out, int sigclass )
ops->pubkey_algo = sk->pubkey_algo; ops->pubkey_algo = sk->pubkey_algo;
keyid_from_sk (sk, ops->keyid); keyid_from_sk (sk, ops->keyid);
ops->last = (skcount == 1); ops->last = (skcount == 1);
init_packet(&pkt); init_packet(&pkt);
pkt.pkttype = PKT_ONEPASS_SIG; pkt.pkttype = PKT_ONEPASS_SIG;
pkt.pkt.onepass_sig = ops; pkt.pkt.onepass_sig = ops;
@ -611,7 +611,7 @@ write_plaintext_packet (IOBUF out, IOBUF inp, const char *fname,
wipememory(copy_buffer,4096); /* burn buffer */ wipememory(copy_buffer,4096); /* burn buffer */
} }
/* fixme: it seems that we never freed pt/pkt */ /* fixme: it seems that we never freed pt/pkt */
return rc; return rc;
} }
@ -923,7 +923,7 @@ sign_file( STRLIST filenames, int detached, STRLIST locusr,
there is an assumed preference for uncompressed data. there is an assumed preference for uncompressed data.
Still, if it did fail, we'll also end up with the Still, if it did fail, we'll also end up with the
default. */ default. */
if((compr_algo= if((compr_algo=
select_algo_from_prefs(pk_list,PREFTYPE_ZIP,-1,NULL))==-1) select_algo_from_prefs(pk_list,PREFTYPE_ZIP,-1,NULL))==-1)
compr_algo=default_compress_algo(); compr_algo=default_compress_algo();
@ -1095,7 +1095,7 @@ clearsign_file( const char *fname, STRLIST locusr, const char *outfile )
outfile = NULL; outfile = NULL;
errno = EPERM; errno = EPERM;
} }
else else
out = iobuf_create( outfile ); out = iobuf_create( outfile );
if( !out ) if( !out )
{ {
@ -1222,7 +1222,7 @@ sign_symencrypt_file (const char *fname, STRLIST locusr)
} }
rc = build_sk_list (locusr, &sk_list, 1, PUBKEY_USAGE_SIG); rc = build_sk_list (locusr, &sk_list, 1, PUBKEY_USAGE_SIG);
if (rc) if (rc)
goto leave; goto leave;
/* prepare iobufs */ /* prepare iobufs */
@ -1234,7 +1234,7 @@ sign_symencrypt_file (const char *fname, STRLIST locusr)
errno = EPERM; errno = EPERM;
} }
if( !inp ) { if( !inp ) {
log_error(_("can't open `%s': %s\n"), log_error(_("can't open `%s': %s\n"),
fname? fname: "[stdin]", strerror(errno) ); fname? fname: "[stdin]", strerror(errno) );
rc = G10ERR_OPEN_FILE; rc = G10ERR_OPEN_FILE;
goto leave; goto leave;
@ -1326,7 +1326,7 @@ sign_symencrypt_file (const char *fname, STRLIST locusr)
create_time); create_time);
if (rc) if (rc)
goto leave; goto leave;
/* Write the signatures */ /* Write the signatures */
/*(current filters: zip - encrypt - armor)*/ /*(current filters: zip - encrypt - armor)*/
rc = write_signature_packets (sk_list, out, mfx.md, rc = write_signature_packets (sk_list, out, mfx.md,
@ -1482,7 +1482,7 @@ int
update_keysig_packet( PKT_signature **ret_sig, update_keysig_packet( PKT_signature **ret_sig,
PKT_signature *orig_sig, PKT_signature *orig_sig,
PKT_public_key *pk, PKT_public_key *pk,
PKT_user_id *uid, PKT_user_id *uid,
PKT_public_key *subpk, PKT_public_key *subpk,
PKT_secret_key *sk, PKT_secret_key *sk,
int (*mksubpkt)(PKT_signature *, void *), int (*mksubpkt)(PKT_signature *, void *),
@ -1514,7 +1514,7 @@ update_keysig_packet( PKT_signature **ret_sig,
/* create a new signature packet */ /* create a new signature packet */
sig = copy_signature (NULL, orig_sig); sig = copy_signature (NULL, orig_sig);
/* We need to create a new timestamp so that new sig expiration /* We need to create a new timestamp so that new sig expiration
calculations are done correctly... */ calculations are done correctly... */
sig->timestamp=make_timestamp(); sig->timestamp=make_timestamp();

View File

@ -53,7 +53,7 @@ typedef enum {
/* put flag values into an enum, so that gdb can display them */ /* put flag values into an enum, so that gdb can display them */
enum enum
{ {
HTTP_FLAG_NO_SHUTDOWN = 1 HTTP_FLAG_NO_SHUTDOWN = 1
}; };

View File

@ -94,7 +94,7 @@ init_sockets (void)
return; return;
if( WSAStartup( 0x0101, &wsdata ) ) { if( WSAStartup( 0x0101, &wsdata ) ) {
log_error ("error initializing socket library: ec=%d\n", log_error ("error initializing socket library: ec=%d\n",
(int)WSAGetLastError () ); (int)WSAGetLastError () );
return; return;
} }
@ -205,7 +205,7 @@ http_wait_response( HTTP_HD hd, unsigned int *ret_status )
http_start_data( hd ); /* make sure that we are in the data */ http_start_data( hd ); /* make sure that we are in the data */
#if 0 #if 0
hd->sock = dup( hd->sock ); hd->sock = dup( hd->sock );
if( hd->sock == -1 ) if( hd->sock == -1 )
return G10ERR_GENERAL; return G10ERR_GENERAL;
#endif #endif
@ -843,9 +843,9 @@ connect_server( const char *server, ushort port, unsigned int flags,
return -1; return -1;
} }
addr.sin_family=AF_INET; addr.sin_family=AF_INET;
addr.sin_port=htons(port); addr.sin_port=htons(port);
memcpy(&addr.sin_addr,&inaddr,sizeof(inaddr)); memcpy(&addr.sin_addr,&inaddr,sizeof(inaddr));
if(connect(sock,(struct sockaddr *)&addr,sizeof(addr))==0) if(connect(sock,(struct sockaddr *)&addr,sizeof(addr))==0)
return sock; return sock;
@ -1025,7 +1025,7 @@ write_server( int sock, const char *data, size_t length )
nleft = length; nleft = length;
while( nleft > 0 ) { while( nleft > 0 ) {
#ifdef _WIN32 #ifdef _WIN32
int nwritten; int nwritten;
nwritten = send (sock, data, nleft, 0); nwritten = send (sock, data, nleft, 0);