aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Shaw <[email protected]>2003-05-24 18:38:35 +0000
committerDavid Shaw <[email protected]>2003-05-24 18:38:35 +0000
commitea35e3b65f5e741ce2feebd53831681f9e807884 (patch)
tree43d449ca34f21b926a5233000897bc3cc5d8bfcd
parent* bithelp.h, des.c, random.c, rndlinux.c, sha1.c, blowfish.c, elgamal.c, (diff)
downloadgnupg-ea35e3b65f5e741ce2feebd53831681f9e807884.tar.gz
gnupg-ea35e3b65f5e741ce2feebd53831681f9e807884.zip
* bftest.c, crlf.c, mk-tdata.c, mpicalc.c, shmtest.c: Edit all
preprocessor instructions to remove whitespace before the '#'. This is not required by C89, but there are some compilers out there that don't like it.
-rw-r--r--tools/ChangeLog7
-rw-r--r--tools/bftest.c27
-rw-r--r--tools/crlf.c5
-rw-r--r--tools/mk-tdata.c9
-rw-r--r--tools/mpicalc.c20
-rw-r--r--tools/shmtest.c23
6 files changed, 46 insertions, 45 deletions
diff --git a/tools/ChangeLog b/tools/ChangeLog
index fa334ad31..0643e1f0a 100644
--- a/tools/ChangeLog
+++ b/tools/ChangeLog
@@ -1,3 +1,10 @@
+2003-05-24 David Shaw <[email protected]>
+
+ * bftest.c, crlf.c, mk-tdata.c, mpicalc.c, shmtest.c: Edit all
+ preprocessor instructions to remove whitespace before the
+ '#'. This is not required by C89, but there are some compilers out
+ there that don't like it.
+
2003-03-11 David Shaw <[email protected]>
* Makefile.am: Use @CAPLIBS@ to link in -lcap if we are using
diff --git a/tools/bftest.c b/tools/bftest.c
index b15f4a1da..67a80e33d 100644
--- a/tools/bftest.c
+++ b/tools/bftest.c
@@ -23,8 +23,8 @@
#include <stdlib.h>
#include <string.h>
#ifdef HAVE_DOSISH_SYSTEM
- #include <io.h>
- #include <fcntl.h>
+#include <io.h>
+#include <fcntl.h>
#endif
#include "util.h"
@@ -47,15 +47,15 @@ strusage( int level )
static void
i18n_init(void)
{
- #ifdef ENABLE_NLS
- #ifdef HAVE_LC_MESSAGES
- setlocale( LC_MESSAGES, "" );
- #else
- setlocale( LC_ALL, "" );
- #endif
- bindtextdomain( PACKAGE, G10_LOCALEDIR );
- textdomain( PACKAGE );
- #endif
+#ifdef ENABLE_NLS
+#ifdef HAVE_LC_MESSAGES
+ setlocale( LC_MESSAGES, "" );
+#else
+ setlocale( LC_ALL, "" );
+#endif
+ bindtextdomain( PACKAGE, G10_LOCALEDIR );
+ textdomain( PACKAGE );
+#endif
}
int
@@ -67,10 +67,10 @@ main(int argc, char **argv)
int n, size=4096;
int algo;
- #ifdef HAVE_DOSISH_SYSTEM
+#ifdef HAVE_DOSISH_SYSTEM
setmode( fileno(stdin), O_BINARY );
setmode( fileno(stdout), O_BINARY );
- #endif
+#endif
i18n_init();
if( argc > 1 && !strcmp(argv[1], "-e") ) {
@@ -109,4 +109,3 @@ main(int argc, char **argv)
cipher_close(hd);
return 0;
}
-
diff --git a/tools/crlf.c b/tools/crlf.c
index e6ac8c70f..ecb6eecdb 100644
--- a/tools/crlf.c
+++ b/tools/crlf.c
@@ -25,12 +25,12 @@ main(int argc, char **argv)
lc = -1;
while( (c=getchar()) != EOF ) {
- #if 0
+#if 0
if( c == '\r' && lc == ' ' )
fprintf(stderr,"SP,CR at %d\n", off );
if( c == '\n' && lc == ' ' )
fprintf(stderr,"SP,LF at %d\n", off );
- #endif
+#endif
if( c == '\n' && lc == '\r' )
putchar(c);
else if( c == '\n' ) {
@@ -50,4 +50,3 @@ main(int argc, char **argv)
return 0;
}
-
diff --git a/tools/mk-tdata.c b/tools/mk-tdata.c
index dcfa859f1..868e0ffbf 100644
--- a/tools/mk-tdata.c
+++ b/tools/mk-tdata.c
@@ -17,7 +17,7 @@
#ifndef RAND_MAX /* for SunOS */
- #define RAND_MAX 32767
+#define RAND_MAX 32767
#endif
int
@@ -31,13 +31,12 @@ main(int argc, char **argv)
srand(getpid());
for(i=0; !limit || i < limit; i++ ) {
- #ifdef HAVE_RAND
+#ifdef HAVE_RAND
c = ((unsigned)(1 + (int) (256.0*rand()/(RAND_MAX+1.0)))-1);
- #else
+#else
c = ((unsigned)(1 + (int) (256.0*random()/(RAND_MAX+1.0)))-1);
- #endif
+#endif
putchar(c);
}
return 0;
}
-
diff --git a/tools/mpicalc.c b/tools/mpicalc.c
index 2817c9932..e582ff609 100644
--- a/tools/mpicalc.c
+++ b/tools/mpicalc.c
@@ -65,15 +65,15 @@ strusage( int level )
static void
i18n_init(void)
{
- #ifdef ENABLE_NLS
- #ifdef HAVE_LC_MESSAGES
- setlocale( LC_MESSAGES, "" );
- #else
- setlocale( LC_ALL, "" );
- #endif
- bindtextdomain( PACKAGE, G10_LOCALEDIR );
- textdomain( PACKAGE );
- #endif
+#ifdef ENABLE_NLS
+#ifdef HAVE_LC_MESSAGES
+ setlocale( LC_MESSAGES, "" );
+#else
+ setlocale( LC_ALL, "" );
+#endif
+ bindtextdomain( PACKAGE, G10_LOCALEDIR );
+ textdomain( PACKAGE );
+#endif
}
@@ -386,5 +386,3 @@ main(int argc, char **argv)
mpi_free(stack[i]);
return 0;
}
-
-
diff --git a/tools/shmtest.c b/tools/shmtest.c
index fceade1e1..d8bf72b61 100644
--- a/tools/shmtest.c
+++ b/tools/shmtest.c
@@ -19,11 +19,11 @@
#include <signal.h>
#include <unistd.h>
#ifdef HAVE_SYS_IPC_H
- #include <sys/types.h>
- #include <sys/ipc.h>
+#include <sys/types.h>
+#include <sys/ipc.h>
#endif
#ifdef HAVE_SYS_SHM_H
- #include <sys/shm.h>
+#include <sys/shm.h>
#endif
#include "util.h"
#include "ttyio.h"
@@ -55,15 +55,15 @@ strusage( int level )
static void
i18n_init(void)
{
- #ifdef ENABLE_NLS
- #ifdef HAVE_LC_MESSAGES
+#ifdef ENABLE_NLS
+#ifdef HAVE_LC_MESSAGES
setlocale( LC_MESSAGES, "" );
- #else
+#else
setlocale( LC_ALL, "" );
- #endif
+#endif
bindtextdomain( PACKAGE, G10_LOCALEDIR );
textdomain( PACKAGE );
- #endif
+#endif
}
@@ -114,9 +114,9 @@ main(int argc, char **argv)
log_set_name("shmtest");
i18n_init();
- #ifndef USE_SHM_COPROCESSING
+#ifndef USE_SHM_COPROCESSING
log_info("SHM_COPRPOCESSING is not available\n");
- #else
+#else
if( argc < 1 )
my_usage();
@@ -199,8 +199,7 @@ main(int argc, char **argv)
log_error("pclose failed\n");
return 0;
- #endif
+#endif
}
-
#endif