-/* $Id: agrep.c,v 1.18 2006-08-14 10:40:08 adam Exp $
+/* $Id: agrep.c,v 1.19 2006-10-29 17:20:00 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
static int show_lines = 0;
-int agrep_options (argc, argv)
-int argc;
-char **argv;
+int agrep_options (int argc, char **argv)
{
while (--argc > 0)
if (**++argv == '-')
static char *inf_ptr, *inf_flsh;
static int inf_eof, line_no;
-static int inf_flush (fd)
-int fd;
+static int inf_flush (int fd)
{
char *p;
unsigned b, r;
return 0;
}
-static char *prline (p)
-char *p;
+static char *prline (char *p)
{
char *p0;
return p;
}
-static int go (fd, dfaar)
-int fd;
-struct DFA_state **dfaar;
+static int go (int fd, struct DFA_state **dfaar)
{
struct DFA_state *s = dfaar[0];
struct DFA_tran *t;
return 0;
}
-int agrep (dfas, fd)
-struct DFA_state **dfas;
-int fd;
+int agrep (struct DFA_state **dfas, int fd)
{
inf_buf = imalloc (sizeof(char)*INF_BUF_SIZE);
inf_eof = 0;
}
-int main (argc, argv)
-int argc;
-char **argv;
+int main (int argc, char **argv)
{
const char *pattern = NULL;
char outbuf[BUFSIZ];
-/* $Id: isam-codec.h,v 1.4 2006-08-14 10:40:14 adam Exp $
+/* $Id: isam-codec.h,v 1.5 2006-10-29 17:20:00 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
#define ISAM_CODEC_H
typedef struct {
- void *(*start)();
+ void *(*start)(void);
void (*stop)(void *p);
void (*decode)(void *p, char **dst, const char **src);
void (*encode)(void *p, char **dst, const char **src);
-/* $Id: snippet.h,v 1.6 2006-08-14 10:40:14 adam Exp $
+/* $Id: snippet.h,v 1.7 2006-10-29 17:20:00 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
typedef struct zebra_snippet_word zebra_snippet_word;
YAZ_EXPORT
-zebra_snippets *zebra_snippets_create();
+zebra_snippets *zebra_snippets_create(void);
YAZ_EXPORT
void zebra_snippets_destroy(zebra_snippets *l);
-/* $Id: extract.c,v 1.230 2006-09-15 10:45:12 adam Exp $
+/* $Id: extract.c,v 1.231 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
static int log_level = 0;
static int log_level_initialized = 0;
-static void zebra_init_log_level()
+static void zebra_init_log_level(void)
{
if (!log_level_initialized)
{
-/* $Id: index.h,v 1.179 2006-10-12 12:28:42 adam Exp $
+/* $Id: index.h,v 1.180 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
void zebra_livcode_transform(ZebraHandle zh, Z_RPNQuery *query);
-void *iscz1_start ();
+void *iscz1_start (void);
void iscz1_reset (void *vp);
void iscz1_stop (void *p);
void iscz1_decode (void *vp, char **dst, const char **src);
-/* $Id: kinput.c,v 1.76 2006-08-14 10:40:15 adam Exp $
+/* $Id: kinput.c,v 1.77 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
int no_iterations;
};
-static struct heap_info *key_heap_malloc()
+static struct heap_info *key_heap_malloc(void)
{ /* malloc and clear it */
struct heap_info *hi;
hi = (struct heap_info *) xmalloc (sizeof(*hi));
-/* $Id: recgrs.c,v 1.8 2006-10-26 23:45:46 adam Exp $
+/* $Id: recgrs.c,v 1.9 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
return 1;
}
-static struct source_parser *source_parser_create()
+static struct source_parser *source_parser_create(void)
{
struct source_parser *sp = xmalloc(sizeof(*sp));
-/* $Id: reckeys.c,v 1.7 2006-08-14 10:40:15 adam Exp $
+/* $Id: reckeys.c,v 1.8 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
}
}
-zebra_rec_keys_t zebra_rec_keys_open()
+zebra_rec_keys_t zebra_rec_keys_open(void)
{
zebra_rec_keys_t p = xmalloc(sizeof(*p));
p->buf_used = 0;
-/* $Id: reckeys.h,v 1.5 2006-08-14 10:40:15 adam Exp $
+/* $Id: reckeys.h,v 1.6 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
typedef struct zebra_rec_keys_t_ *zebra_rec_keys_t;
-zebra_rec_keys_t zebra_rec_keys_open();
+zebra_rec_keys_t zebra_rec_keys_open(void);
void zebra_rec_keys_close(zebra_rec_keys_t p);
-/* $Id: zebrash.c,v 1.39 2006-08-14 10:40:15 adam Exp $
+/* $Id: zebrash.c,v 1.40 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
* The shell
*/
-void shell()
+void shell(void)
{
int rc=0;
WRBUF outbuff=wrbuf_alloc();
} /* shell() */
-static void usage()
+static void usage(void)
{
printf ("usage:\n");
printf ("zebrash [-c config]\n");
-/* $Id: zsets.c,v 1.111 2006-09-20 10:51:25 adam Exp $
+/* $Id: zsets.c,v 1.112 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
static int log_level_searchterms=0;
static int log_level_resultsets=0;
-static void loglevels()
+static void loglevels(void)
{
if (log_level_set)
return;
-/* $Id: testlib.c,v 1.38 2006-09-08 09:56:40 adam Exp $
+/* $Id: testlib.c,v 1.39 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
/**
* get_srcdir: return env srcdir or . (if does does not exist)
*/
-const char *tl_get_srcdir()
+const char *tl_get_srcdir(void)
{
const char *srcdir = getenv("srcdir");
if (!srcdir || ! *srcdir)
-/* $Id: testlib.h,v 1.22 2006-08-23 07:37:02 adam Exp $
+/* $Id: testlib.h,v 1.23 2006-10-29 17:20:01 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
* get_srcdir : returns the source dir. Most often ".", but when
* making distcheck, some other dir
*/
-const char *tl_get_srcdir();
+const char *tl_get_srcdir(void);
/**
* start_log: open a log file
-/* $Id: flock.c,v 1.19 2006-10-27 11:05:14 adam Exp $
+/* $Id: flock.c,v 1.20 2006-10-29 17:20:02 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
* The default posix_locks=1 is assumed.. This function sets posix_locks
* to zero if linuxthreads is in use.
*/
-static int check_for_linuxthreads()
+static int check_for_linuxthreads(void)
{
#if __linux
#ifdef _CS_GNU_LIBPTHREAD_VERSION
-/* $Id: snippet.c,v 1.10 2006-08-14 10:40:34 adam Exp $
+/* $Id: snippet.c,v 1.11 2006-10-29 17:20:02 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
zebra_snippet_word *tail;
};
-zebra_snippets *zebra_snippets_create()
+zebra_snippets *zebra_snippets_create(void)
{
NMEM nmem = nmem_create();
zebra_snippets *l = nmem_malloc(nmem, sizeof(*l));
-/* $Id: tstcharmap.c,v 1.5 2006-08-14 10:40:34 adam Exp $
+/* $Id: tstcharmap.c,v 1.6 2006-10-29 17:20:02 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
#include <yaz/log.h>
/* use env srcdir as base directory - or current directory if unset */
-const char *get_srcdir()
+const char *get_srcdir(void)
{
const char *srcdir = getenv("srcdir");
if (!srcdir || ! *srcdir)
}
-void tst1()
+void tst1(void)
{
/* open existing map chrmaptab.chr */
chrmaptab tab = chrmaptab_create(get_srcdir() /* tabpath */,
chrmaptab_destroy(tab);
}
-void tst2()
+void tst2(void)
{
/* open non-existing nonexist.chr */
chrmaptab tab = chrmaptab_create(get_srcdir() /* tabpath */,
-/* $Id: tstflock.c,v 1.16 2006-08-14 10:40:34 adam Exp $
+/* $Id: tstflock.c,v 1.17 2006-10-29 17:20:02 adam Exp $
Copyright (C) 1995-2006
Index Data ApS
int test_fd = 0;
-static void small_sleep()
+static void small_sleep(void)
{
#ifdef WIN32
Sleep(2);
num, write_flag, seq);
}
-static void tst()
+static void tst(void)
{
tst_thread(4, 1); /* write locks */
if (1)
tst_thread(20, 2); /* random locks */
}
-void fork_tst()
+void fork_tst(void)
{
#if HAVE_SYS_WAIT_H
pid_t pid[2];