summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/client/client.c52
-rw-r--r--source3/client/clientutil.c2
-rw-r--r--source3/client/clitar.c48
-rw-r--r--source3/include/includes.h13
-rw-r--r--source3/include/proto.h139
-rw-r--r--source3/include/smb.h2
-rw-r--r--source3/lib/access.c4
-rw-r--r--source3/lib/charcnv.c10
-rw-r--r--source3/lib/fault.c4
-rw-r--r--source3/lib/getsmbpass.c2
-rw-r--r--source3/lib/interface.c2
-rw-r--r--source3/lib/system.c2
-rw-r--r--source3/lib/username.c8
-rw-r--r--source3/lib/util.c4
-rw-r--r--source3/libsmb/namequery.c7
-rw-r--r--source3/nmbd/asyncdns.c6
-rw-r--r--source3/nmbd/nmbd.c6
-rw-r--r--source3/nmbd/nmbd_mynames.c4
-rw-r--r--source3/nmbd/nmbd_namelistdb.c2
-rw-r--r--source3/nmbd/nmbd_packets.c2
-rw-r--r--source3/nmbd/nmbd_sendannounce.c2
-rw-r--r--source3/nmbd/nmbd_subnetdb.c4
-rw-r--r--source3/param/loadparm.c2
-rw-r--r--source3/passdb/smbpass.c2
-rw-r--r--source3/printing/pcap.c2
-rw-r--r--source3/printing/print_svid.c4
-rw-r--r--source3/smbd/ipc.c58
-rw-r--r--source3/smbd/message.c8
-rw-r--r--source3/smbd/password.c4
-rw-r--r--source3/smbd/predict.c2
-rw-r--r--source3/smbd/reply.c83
-rw-r--r--source3/smbd/server.c16
-rw-r--r--source3/utils/make_printerdef.c2
33 files changed, 243 insertions, 265 deletions
diff --git a/source3/client/client.c b/source3/client/client.c
index d58644e09b..9abdb00350 100644
--- a/source3/client/client.c
+++ b/source3/client/client.c
@@ -80,7 +80,7 @@ extern BOOL have_ip;
extern int max_xmit;
static int interpret_long_filename(int level,char *p,file_info *finfo);
-static void dir_action(char *inbuf,char *outbuf,int attribute,file_info *finfo,BOOL recurse_dir,void (*fn)(),BOOL longdir, BOOL dirstoo);
+static void dir_action(char *inbuf,char *outbuf,int attribute,file_info *finfo,BOOL recurse_dir,void (*fn)(file_info *),BOOL longdir, BOOL dirstoo);
static int interpret_short_filename(char *p,file_info *finfo);
static BOOL do_this_one(file_info *finfo);
@@ -405,7 +405,7 @@ static void do_dskattr(void)
/****************************************************************************
show cd/pwd
****************************************************************************/
-static void cmd_pwd(void)
+static void cmd_pwd(char *dum_in, char *dum_out)
{
DEBUG(0,("Current directory is %s",CNV_LANG(service)));
DEBUG(0,("%s\n",CNV_LANG(cur_dir)));
@@ -478,7 +478,7 @@ static void display_finfo(file_info *finfo)
do a directory listing, calling fn on each file found. Use the TRANSACT2
call for long filenames
****************************************************************************/
-static int do_long_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(),BOOL recurse_dir, BOOL dirstoo)
+static int do_long_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(file_info *),BOOL recurse_dir, BOOL dirstoo)
{
int max_matches = 512;
int info_level = Protocol<PROTOCOL_NT1?1:260; /* NT uses 260, OS/2 uses 2. Both accept 1. */
@@ -650,7 +650,7 @@ static int do_long_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*
/****************************************************************************
do a directory listing, calling fn on each file found
****************************************************************************/
-static int do_short_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(),BOOL recurse_dir, BOOL dirstoo)
+static int do_short_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(file_info *),BOOL recurse_dir, BOOL dirstoo)
{
char *p;
int received = 0;
@@ -789,7 +789,7 @@ static int do_short_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (
/****************************************************************************
do a directory listing, calling fn on each file found
****************************************************************************/
-void do_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(),BOOL recurse_dir, BOOL dirstoo)
+void do_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(file_info *),BOOL recurse_dir, BOOL dirstoo)
{
DEBUG(5,("do_dir(%s,%x,%s)\n",Mask,attribute,BOOLSTR(recurse_dir)));
if (Protocol >= PROTOCOL_LANMAN2)
@@ -977,7 +977,7 @@ static int interpret_long_filename(int level,char *p,file_info *finfo)
RJS, 4-Apr-1998, dirstoo added to allow caller to indicate that directories
should be processed as well.
****************************************************************************/
-static void dir_action(char *inbuf,char *outbuf,int attribute,file_info *finfo,BOOL recurse_dir,void (*fn)(),BOOL longdir, BOOL dirstoo)
+static void dir_action(char *inbuf,char *outbuf,int attribute,file_info *finfo,BOOL recurse_dir,void (*fn)(file_info *),BOOL longdir, BOOL dirstoo)
{
if (!((finfo->mode & aDIR) == 0 && *fileselection &&
@@ -1454,7 +1454,7 @@ static void do_get(char *rname,char *lname,file_info *finfo1)
/****************************************************************************
get a file
****************************************************************************/
-static void cmd_get(void)
+static void cmd_get(char *dum_in, char *dum_out)
{
pstring lname;
pstring rname;
@@ -1565,7 +1565,7 @@ static void do_mget(file_info *finfo)
/****************************************************************************
view the file using the pager
****************************************************************************/
-static void cmd_more(void)
+static void cmd_more(char *dum_in, char *dum_out)
{
fstring rname,lname,tmpname,pager_cmd;
char *pager;
@@ -1954,7 +1954,7 @@ static void do_put(char *rname,char *lname,file_info *finfo)
/****************************************************************************
put a file
****************************************************************************/
-static void cmd_put(void)
+static void cmd_put(char *dum_in, char *dum_out)
{
pstring lname;
pstring rname;
@@ -2018,7 +2018,7 @@ static BOOL seek_list(FILE *f,char *name)
/****************************************************************************
set the file selection mask
****************************************************************************/
-static void cmd_select(void)
+static void cmd_select(char *dum_in, char *dum_out)
{
strcpy(fileselection,"");
next_token(NULL,fileselection,NULL);
@@ -2028,7 +2028,7 @@ static void cmd_select(void)
/****************************************************************************
mput some files
****************************************************************************/
-static void cmd_mput(void)
+static void cmd_mput(char *dum_in, char *dum_out)
{
pstring lname;
pstring rname;
@@ -2777,7 +2777,7 @@ static void cmd_rename(char *inbuf,char *outbuf )
/****************************************************************************
toggle the prompt flag
****************************************************************************/
-static void cmd_prompt(void)
+static void cmd_prompt(char *dum_in, char *dum_out)
{
prompt = !prompt;
DEBUG(2,("prompting is now %s\n",prompt?"on":"off"));
@@ -2787,7 +2787,7 @@ static void cmd_prompt(void)
/****************************************************************************
set the newer than time
****************************************************************************/
-static void cmd_newer(void)
+static void cmd_newer(char *dum_in, char *dum_out)
{
fstring buf;
BOOL ok;
@@ -2810,7 +2810,7 @@ static void cmd_newer(void)
/****************************************************************************
set the archive level
****************************************************************************/
-static void cmd_archive(void)
+static void cmd_archive(char *dum_in, char *dum_out)
{
fstring buf;
@@ -2823,7 +2823,7 @@ static void cmd_archive(void)
/****************************************************************************
toggle the lowercaseflag
****************************************************************************/
-static void cmd_lowercase(void)
+static void cmd_lowercase(char *dum_in, char *dum_out)
{
lowercase = !lowercase;
DEBUG(2,("filename lowercasing is now %s\n",lowercase?"on":"off"));
@@ -2835,7 +2835,7 @@ static void cmd_lowercase(void)
/****************************************************************************
toggle the recurse flag
****************************************************************************/
-static void cmd_recurse(void)
+static void cmd_recurse(char *dum_in, char *dum_out)
{
recurse = !recurse;
DEBUG(2,("directory recursion is now %s\n",recurse?"on":"off"));
@@ -2844,7 +2844,7 @@ static void cmd_recurse(void)
/****************************************************************************
toggle the translate flag
****************************************************************************/
-static void cmd_translate(void)
+static void cmd_translate(char *dum_in, char *dum_out)
{
translation = !translation;
DEBUG(2,("CR/LF<->LF and print text translation now %s\n",
@@ -2855,7 +2855,7 @@ static void cmd_translate(void)
/****************************************************************************
do a printmode command
****************************************************************************/
-static void cmd_printmode(void)
+static void cmd_printmode(char *dum_in, char *dum_out)
{
fstring buf;
fstring mode;
@@ -2892,7 +2892,7 @@ static void cmd_printmode(void)
/****************************************************************************
do the lcd command
****************************************************************************/
-static void cmd_lcd(void)
+static void cmd_lcd(char *dum_in, char *dum_out)
{
fstring buf;
pstring d;
@@ -2916,8 +2916,6 @@ static BOOL browse_host(BOOL sort)
#define strcasecmp StrCaseCmp
#endif /* NOSTRCASECMP */
- extern int strcasecmp();
-
char *rparam = NULL;
char *rdata = NULL;
char *p;
@@ -3008,7 +3006,7 @@ static BOOL browse_host(BOOL sort)
/****************************************************************************
get some server info
****************************************************************************/
-static void server_info()
+static void server_info(void)
{
char *rparam = NULL;
char *rdata = NULL;
@@ -3187,7 +3185,7 @@ static BOOL list_servers(char *wk_grp)
struct
{
char *name;
- void (*fn)();
+ void (*fn)(char *, char *);
char *description;
} commands[] =
{
@@ -3273,7 +3271,7 @@ static int process_tok(fstring tok)
/****************************************************************************
help
****************************************************************************/
-void cmd_help(void)
+void cmd_help(char *dum_in, char *dum_out)
{
int i=0,j;
fstring buf;
@@ -3485,7 +3483,7 @@ static BOOL process(char *base_directory)
DEBUG(0,("%s: command not found\n",CNV_LANG(tok)));
}
- cli_send_logout();
+ cli_send_logout(InBuffer,OutBuffer);
return(True);
}
@@ -3806,7 +3804,7 @@ static void usage(char *pname)
ret=process_tar(InBuffer, OutBuffer);
- cli_send_logout();
+ cli_send_logout(InBuffer, OutBuffer);
close_sockets();
return(ret);
} else
@@ -3837,7 +3835,7 @@ static void usage(char *pname)
list_servers(workgroup);
}
- cli_send_logout();
+ cli_send_logout(NULL,NULL);
close_sockets();
}
diff --git a/source3/client/clientutil.c b/source3/client/clientutil.c
index 2afac354c2..dce34eda2c 100644
--- a/source3/client/clientutil.c
+++ b/source3/client/clientutil.c
@@ -824,7 +824,7 @@ BOOL cli_send_login(char *inbuf,char *outbuf,BOOL start_session,BOOL use_setup,
/****************************************************************************
send a logout command
****************************************************************************/
-void cli_send_logout(void )
+void cli_send_logout(char *dum_in, char *dum_out)
{
pstring inbuf,outbuf;
diff --git a/source3/client/clitar.c b/source3/client/clitar.c
index 130c5e7a27..32731200b0 100644
--- a/source3/client/clitar.c
+++ b/source3/client/clitar.c
@@ -86,21 +86,13 @@ int tarhandle;
static void writetarheader(int f, char *aname, int size, time_t mtime,
char *amode, unsigned char ftype);
-static void do_atar();
-static void do_tar();
-static void oct_it();
-static void fixtarname();
-static int dotarbuf();
-static void dozerobuf();
-static void dotareof();
-static void initarbuf();
-static int do_setrattr();
-
-/* restore functions */
-static long readtarheader();
-static long unoct();
-static void do_tarput();
-static void unfixtarname();
+
+/* Forward references. */
+static void fixtarname(char *tptr, char *fp, int l);
+static int dotarbuf(int f, char *b, int n);
+static void oct_it (long value, int ndgs, char *p);
+static long unoct(char *p, int ndgs);
+static void unfixtarname(char *tptr, char *fp, int l);
/*
* tar specific utitlities
@@ -306,7 +298,7 @@ static void dozerobuf(int f, int n)
/****************************************************************************
Malloc tape buffer
****************************************************************************/
-static void initarbuf()
+static void initarbuf(void)
{
/* initialize tar buffer */
tbufsiz=blocksize*TBLOCK;
@@ -373,7 +365,7 @@ static void fixtarname(char *tptr, char *fp, int l)
/****************************************************************************
Convert from decimal to octal string
****************************************************************************/
-static void oct_it (register long value, register int ndgs, register char *p)
+static void oct_it (long value, int ndgs, char *p)
{
/* Converts long to octal string, pads with leading zeros */
@@ -1353,21 +1345,7 @@ static void unfixtarname(char *tptr, char *fp, int l)
}
}
-/****************************************************************************
-Move to the next block in the buffer, which may mean read in another set of
-blocks.
-****************************************************************************/
-int next_block(char *tarbuf, char *bufferp, int bufsiz)
-{
- int bufread, total = 0;
-
- for (bufread = read(tarhandle, tarbuf, bufsiz); total += bufread; total < bufsiz) {
-
- }
-
-}
-
-static void do_tarput()
+static void do_tarput(void)
{
file_info finfo;
int nread=0, bufread;
@@ -1653,7 +1631,7 @@ static void do_tarput()
/****************************************************************************
Blocksize command
***************************************************************************/
-void cmd_block(void)
+void cmd_block(char *dum_in, char *dum_out)
{
fstring buf;
int block;
@@ -1678,7 +1656,7 @@ void cmd_block(void)
/****************************************************************************
command to set incremental / reset mode
***************************************************************************/
-void cmd_tarmode(void)
+void cmd_tarmode(char *dum_in, char *dum_out)
{
fstring buf;
@@ -1718,7 +1696,7 @@ void cmd_tarmode(void)
/****************************************************************************
Feeble attrib command
***************************************************************************/
-void cmd_setmode(void)
+void cmd_setmode(char *dum_in, char *dum_out)
{
char *q;
fstring buf;
diff --git a/source3/include/includes.h b/source3/include/includes.h
index a1723a55c6..8cc2711e0a 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -521,12 +521,13 @@ char *mktemp(char *); /* No standard include */
#include <netinet/in_systm.h>
#include <netinet/ip.h>
#include <termios.h>
+#include <fcntl.h>
#if __FreeBSD__ >= 3
#include <dirent.h>
#else
#define USE_DIRECT
#endif
-#define SIGNAL_CAST (void (*)())
+#define SIGNAL_CAST (void (*)(int))
#define USE_SETVBUF
#define USE_SETSID
#define USE_GETCWD
@@ -536,7 +537,15 @@ char *mktemp(char *); /* No standard include */
#define HAVE_GETTIMEOFDAY
#define HAVE_PATHCONF
#define HAVE_GETGRNAM 1
-#endif
+#define QSORT_CAST (int (*)(const void *, const void *))
+#if !defined(O_SYNC)
+#if defined(O_FSYNC)
+#define O_SYNC O_FSYNC
+#else /* defined(O_FSYNC) */
+#define O_SYNC 0
+#endif /* defined(O_FSYNC) */
+#endif /* !defined(O_SYNC) */
+#endif /* FreeBSD */
#ifdef __OpenBSD__
#include <strings.h>
diff --git a/source3/include/proto.h b/source3/include/proto.h
index d49111fabb..fb95a7d525 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -9,14 +9,14 @@ BOOL allow_access(char *deny_list,char *allow_list,char *cname,char *caddr);
/*The following definitions come from asyncdns.c */
int asyncdns_fd(void);
-void kill_async_dns_child();
+void kill_async_dns_child(void);
void start_async_dns(void);
void run_dns_queue(void);
BOOL queue_dns_query(struct packet_struct *p,struct nmb_name *question,
struct name_record **n);
BOOL queue_dns_query(struct packet_struct *p,struct nmb_name *question,
struct name_record **n);
-void kill_async_dns_child();
+void kill_async_dns_child(void);
/*The following definitions come from charcnv.c */
@@ -46,8 +46,8 @@ BOOL change_oem_password(struct smb_passwd *smbpw, char *new_passwd);
/*The following definitions come from client.c */
void cli_smb_close(char *inbuf, char *outbuf, int clnt_fd, int c_num, int f_num);
-void do_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(),BOOL recurse_dir,BOOL dirstoo);
-void cmd_help(void);
+void do_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(file_info *),BOOL recurse_dir, BOOL dirstoo);
+void cmd_help(char *dum_in, char *dum_out);
/*The following definitions come from clientgen.c */
@@ -114,16 +114,16 @@ BOOL cli_send_trans_request(char *outbuf,int trans,
int mdata,int mparam,int msetup);
BOOL cli_send_session_request(char *inbuf,char *outbuf);
BOOL cli_send_login(char *inbuf,char *outbuf,BOOL start_session,BOOL use_setup, struct connection_options *options);
-void cli_send_logout(void );
+void cli_send_logout(char *dum_in, char *dum_out);
BOOL cli_open_sockets(int port );
BOOL cli_reopen_connection(char *inbuf,char *outbuf);
/*The following definitions come from clitar.c */
int padit(char *buf, int bufsize, int padsize);
-void cmd_block(void);
-void cmd_tarmode(void);
-void cmd_setmode(void);
+void cmd_block(char *dum_in, char *dum_out);
+void cmd_tarmode(char *dum_in, char *dum_out);
+void cmd_setmode(char *dum_in, char *dum_out);
void cmd_tar(char *inbuf, char *outbuf);
int process_tar(char *inbuf, char *outbuf);
int clipfind(char **aret, int ret, char *tok);
@@ -179,7 +179,7 @@ void DirCacheFlush( int snum );
/*The following definitions come from fault.c */
-void fault_setup(void (*fn)());
+void fault_setup(void (*fn)(void *));
/*The following definitions come from getsmbpass.c */
@@ -193,7 +193,7 @@ BOOL ismyip(struct in_addr ip);
BOOL ismybcast(struct in_addr bcast);
BOOL is_local_net(struct in_addr from);
int iface_count(void);
-BOOL we_are_multihomed();
+BOOL we_are_multihomed(void);
struct interface *get_interface(int n);
struct in_addr *iface_n_ip(int n);
struct in_addr *iface_bcast(struct in_addr ip);
@@ -1125,19 +1125,18 @@ char *mem_data(struct mem_buf **buf, uint32 offset);
/*The following definitions come from message.c */
-int reply_sends(char *inbuf,char *outbuf);
-int reply_sendstrt(char *inbuf,char *outbuf);
-int reply_sendtxt(char *inbuf,char *outbuf);
-int reply_sendend(char *inbuf,char *outbuf);
+int reply_sends(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_sendstrt(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_sendtxt(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_sendend(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
/*The following definitions come from namequery.c */
BOOL name_status(int fd,char *name,int name_type,BOOL recurse,
struct in_addr to_ip,char *master,char *rname,
- void (*fn)());
-struct in_addr *name_query(int fd,char *name,int name_type,
- BOOL bcast,BOOL recurse,
- struct in_addr to_ip, int *count, void (*fn)());
+ void (*fn)(struct packet_struct *));
+struct in_addr *name_query(int fd,char *name,int name_type, BOOL bcast,BOOL recurse,
+ struct in_addr to_ip, int *count, void (*fn)(struct packet_struct *));
FILE *startlmhosts(char *fname);
BOOL getlmhostsent( FILE *fp, char *name, int *name_type, struct in_addr *ipaddr);
void endlmhosts(FILE *fp);
@@ -1230,8 +1229,8 @@ void add_logon_names(void);
/*The following definitions come from nmbd_mynames.c */
-BOOL register_my_workgroup_and_names();
-void release_my_names();
+BOOL register_my_workgroup_and_names(void);
+void release_my_names(void);
void refresh_my_names(time_t t);
/*The following definitions come from nmbd_namelistdb.c */
@@ -1263,7 +1262,7 @@ void standard_success_release(struct subnet_record *subrec,
void expire_names_on_subnet(struct subnet_record *subrec, time_t t);
void expire_names(time_t t);
void add_samba_names_to_subnet(struct subnet_record *subrec);
-void dump_all_namelists();
+void dump_all_namelists(void);
/*The following definitions come from nmbd_namequery.c */
@@ -1358,7 +1357,7 @@ void process_browse_packet(struct packet_struct *p, char *buf,int len);
void process_lanman_packet(struct packet_struct *p, char *buf,int len);
BOOL validate_nmb_response_packet( struct nmb_packet *nmb );
BOOL validate_nmb_packet( struct nmb_packet *nmb );
-void run_packet_queue();
+void run_packet_queue(void);
void retransmit_or_expire_response_records(time_t t);
BOOL listen_for_packets(BOOL run_election);
BOOL send_mailslot(BOOL unique, char *mailslot,char *buf,int len,
@@ -1394,7 +1393,7 @@ void send_browser_reset(int reset_type, char *to_name, int to_type, struct in_ad
void broadcast_announce_request(struct subnet_record *subrec, struct work_record *work);
void announce_my_server_names(time_t t);
void announce_my_lm_server_names(time_t t);
-void reset_announce_timer();
+void reset_announce_timer(void);
void announce_myself_to_domain_master_browser(time_t t);
void announce_my_servers_removed(void);
void announce_remote(time_t t);
@@ -1414,8 +1413,8 @@ void write_browse_list(time_t t, BOOL force_write);
/*The following definitions come from nmbd_subnetdb.c */
-BOOL create_subnets();
-BOOL we_are_a_wins_client();
+BOOL create_subnets(void);
+BOOL we_are_a_wins_client(void);
struct subnet_record *get_next_subnet_maybe_unicast(struct subnet_record *subrec);
struct subnet_record *get_next_subnet_maybe_unicast_or_wins_server(struct subnet_record *subrec);
@@ -1506,7 +1505,7 @@ BOOL server_validate(char *user, char *domain,
/*The following definitions come from pcap.c */
BOOL pcap_printername_ok(char *pszPrintername, char *pszPrintcapname);
-void pcap_printer_fn(void (*fn)());
+void pcap_printer_fn(void (*fn)(char *, char *));
/*The following definitions come from pidfile.c */
@@ -1522,12 +1521,12 @@ int reply_pipe_close(char *inbuf,char *outbuf);
/*The following definitions come from predict.c */
int read_predict(int fd,int offset,char *buf,char **ptr,int num);
-void do_read_prediction();
+void do_read_prediction(void);
void invalidate_read_prediction(int fd);
/*The following definitions come from print_svid.c */
-void sysv_printer_fn(void (*fn)());
+void sysv_printer_fn(void (*fn)(char *, char *));
int sysv_printername_ok(char *name);
/*The following definitions come from printing.c */
@@ -1560,55 +1559,55 @@ void *memcpy_wrapped(void *d,void *s,int l,char *fname,int line);
/*The following definitions come from reply.c */
int reply_special(char *inbuf,char *outbuf);
-int reply_tcon(char *inbuf,char *outbuf);
+int reply_tcon(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
int reply_tcon_and_X(char *inbuf,char *outbuf,int length,int bufsize);
int reply_unknown(char *inbuf,char *outbuf);
-int reply_ioctl(char *inbuf,char *outbuf);
+int reply_ioctl(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
int reply_sesssetup_and_X(char *inbuf,char *outbuf,int length,int bufsize);
-int reply_chkpth(char *inbuf,char *outbuf);
-int reply_getatr(char *inbuf,char *outbuf);
-int reply_setatr(char *inbuf,char *outbuf);
-int reply_dskattr(char *inbuf,char *outbuf);
-int reply_search(char *inbuf,char *outbuf);
-int reply_fclose(char *inbuf,char *outbuf);
-int reply_open(char *inbuf,char *outbuf);
+int reply_chkpth(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_getatr(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_setatr(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_dskattr(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_search(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_fclose(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_open(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
int reply_open_and_X(char *inbuf,char *outbuf,int length,int bufsize);
int reply_ulogoffX(char *inbuf,char *outbuf,int length,int bufsize);
-int reply_mknew(char *inbuf,char *outbuf);
-int reply_ctemp(char *inbuf,char *outbuf);
-int reply_unlink(char *inbuf,char *outbuf);
-int reply_readbraw(char *inbuf, char *outbuf);
-int reply_lockread(char *inbuf,char *outbuf);
-int reply_read(char *inbuf,char *outbuf);
+int reply_mknew(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_ctemp(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_unlink(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_readbraw(char *inbuf, char *outbuf, int dum_size, int dum_buffsize);
+int reply_lockread(char *inbuf,char *outbuf, int dum_size, int dum_buffsiz);
+int reply_read(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
int reply_read_and_X(char *inbuf,char *outbuf,int length,int bufsize);
-int reply_writebraw(char *inbuf,char *outbuf);
-int reply_writeunlock(char *inbuf,char *outbuf);
-int reply_write(char *inbuf,char *outbuf,int dum1,int dum2);
+int reply_writebraw(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_writeunlock(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_write(char *inbuf,char *outbuf,int dum_size,int dum_buffsize);
int reply_write_and_X(char *inbuf,char *outbuf,int length,int bufsize);
-int reply_lseek(char *inbuf,char *outbuf);
-int reply_flush(char *inbuf,char *outbuf);
-int reply_exit(char *inbuf,char *outbuf);
-int reply_close(char *inbuf,char *outbuf);
-int reply_writeclose(char *inbuf,char *outbuf);
-int reply_lock(char *inbuf,char *outbuf);
-int reply_unlock(char *inbuf,char *outbuf);
-int reply_tdis(char *inbuf,char *outbuf);
-int reply_echo(char *inbuf,char *outbuf);
-int reply_printopen(char *inbuf,char *outbuf);
-int reply_printclose(char *inbuf,char *outbuf);
-int reply_printqueue(char *inbuf,char *outbuf);
-int reply_printwrite(char *inbuf,char *outbuf);
-int reply_mkdir(char *inbuf,char *outbuf);
-int reply_rmdir(char *inbuf,char *outbuf);
-int reply_mv(char *inbuf,char *outbuf);
-int reply_copy(char *inbuf,char *outbuf);
-int reply_setdir(char *inbuf,char *outbuf);
+int reply_lseek(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_flush(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_exit(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_close(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_writeclose(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_lock(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_unlock(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_tdis(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_echo(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_printopen(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_printclose(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_printqueue(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_printwrite(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_mkdir(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_rmdir(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_mv(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_copy(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_setdir(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
int reply_lockingX(char *inbuf,char *outbuf,int length,int bufsize);
int reply_readbmpx(char *inbuf,char *outbuf,int length,int bufsize);
-int reply_writebmpx(char *inbuf,char *outbuf);
-int reply_writebs(char *inbuf,char *outbuf);
-int reply_setattrE(char *inbuf,char *outbuf);
-int reply_getattrE(char *inbuf,char *outbuf);
+int reply_writebmpx(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_writebs(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_setattrE(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
+int reply_getattrE(char *inbuf,char *outbuf, int dum_size, int dum_buffsize);
/*The following definitions come from server.c */
@@ -1880,7 +1879,7 @@ int interpret_security(char *str,int def);
uint32 interpret_addr(char *str);
struct in_addr *interpret_addr2(char *str);
BOOL zero_ip(struct in_addr ip);
-void reset_globals_after_fork();
+void reset_globals_after_fork(void);
char *client_name(int fd);
char *client_addr(int fd);
char *automount_server(char *user_name);
@@ -1903,7 +1902,7 @@ int file_lock(char *name,int timeout);
void file_unlock(int fd);
BOOL is_myname(char *s);
void set_remote_arch(enum remote_arch_types type);
-enum remote_arch_types get_remote_arch();
+enum remote_arch_types get_remote_arch(void);
char *skip_unicode_string(char *buf,int n);
char *unistrn2(uint16 *buf, int len);
char *unistr2(uint16 *buf);
diff --git a/source3/include/smb.h b/source3/include/smb.h
index 33c483d54c..95521217e9 100644
--- a/source3/include/smb.h
+++ b/source3/include/smb.h
@@ -632,7 +632,7 @@ struct parm_struct
parm_type type;
parm_class class;
void *ptr;
- BOOL (*special)();
+ BOOL (*special)(char *, char **);
struct enum_list *enum_list;
unsigned flags;
union {
diff --git a/source3/lib/access.c b/source3/lib/access.c
index cc2bf8632b..fe78700edd 100644
--- a/source3/lib/access.c
+++ b/source3/lib/access.c
@@ -35,7 +35,7 @@ static char sep[] = ", \t";
#define FAIL (-1)
/* Forward declarations. */
-static int list_match(char *list,char *item, int (*match_fn)());
+static int list_match(char *list,char *item, int (*match_fn)(char *, char *));
static int client_match(char *tok,char *item);
static int string_match(char *tok,char *s);
static int masked_match(char *tok, char *slash, char *s);
@@ -118,7 +118,7 @@ BOOL allow_access(char *deny_list,char *allow_list,char *cname,char *caddr)
/* list_match - match an item against a list of tokens with exceptions */
/* (All modifications are marked with the initials "jkf") */
-static int list_match(char *list,char *item, int (*match_fn)())
+static int list_match(char *list,char *item, int (*match_fn)(char *, char *))
{
char *tok;
char *listcopy; /* jkf */
diff --git a/source3/lib/charcnv.c b/source3/lib/charcnv.c
index e92e8170f0..42be32ccb3 100644
--- a/source3/lib/charcnv.c
+++ b/source3/lib/charcnv.c
@@ -30,7 +30,7 @@ static BOOL mapsinited = 0;
static char unix2dos[256];
static char dos2unix[256];
-static void initmaps() {
+static void initmaps(void) {
int k;
for (k = 0; k < 256; k++) unix2dos[k] = k;
@@ -51,7 +51,7 @@ static void update_map(char * str) {
}
}
-static void init_iso8859_1() {
+static void init_iso8859_1(void) {
int i;
if (!mapsinited) initmaps();
@@ -81,7 +81,7 @@ update_map("\370\233\371\227\372\243\373\226\374\201\375\354\376\347\377\230");
/* Init for eastern european languages. */
-static void init_iso8859_2() {
+static void init_iso8859_2(void) {
int i;
if (!mapsinited) initmaps();
@@ -118,7 +118,7 @@ update_map("\377\372");
/* Added by Max Khon <max@iclub.nsu.ru> */
-static void init_iso8859_5()
+static void init_iso8859_5(void)
{
int i;
if (!mapsinited) initmaps();
@@ -145,7 +145,7 @@ update_map("\374\360\377\240");
/* Init for russian language (koi8) */
-static void init_koi8_r()
+static void init_koi8_r(void)
{
if (!mapsinited) initmaps();
diff --git a/source3/lib/fault.c b/source3/lib/fault.c
index e3299c50db..f46ccbb185 100644
--- a/source3/lib/fault.c
+++ b/source3/lib/fault.c
@@ -23,7 +23,7 @@
extern int DEBUGLEVEL;
-static void (*cont_fn)();
+static void (*cont_fn)(void *);
/*******************************************************************
@@ -66,7 +66,7 @@ static void sig_fault(int sig)
/*******************************************************************
setup our fault handlers
********************************************************************/
-void fault_setup(void (*fn)())
+void fault_setup(void (*fn)(void *))
{
cont_fn = fn;
diff --git a/source3/lib/getsmbpass.c b/source3/lib/getsmbpass.c
index 3996c45269..68754f0848 100644
--- a/source3/lib/getsmbpass.c
+++ b/source3/lib/getsmbpass.c
@@ -161,5 +161,5 @@ char *getsmbpass(char *prompt)
#else
- void getsmbpasswd_dummy() {;}
+ void getsmbpasswd_dummy(void) {;}
#endif
diff --git a/source3/lib/interface.c b/source3/lib/interface.c
index 9687e1336c..8c1610e9cb 100644
--- a/source3/lib/interface.c
+++ b/source3/lib/interface.c
@@ -453,7 +453,7 @@ int iface_count(void)
/****************************************************************************
True if we have two or more interfaces.
**************************************************************************/
-BOOL we_are_multihomed()
+BOOL we_are_multihomed(void)
{
static int multi = -1;
diff --git a/source3/lib/system.c b/source3/lib/system.c
index f5fbae53ab..3eef8e5034 100644
--- a/source3/lib/system.c
+++ b/source3/lib/system.c
@@ -215,8 +215,6 @@ static int copy_reg(char *source, const char *dest)
{
struct stat source_stats;
int ifd;
- int full_write();
- int safe_read();
int ofd;
char *buf;
int len; /* Number of bytes read into `buf'. */
diff --git a/source3/lib/username.c b/source3/lib/username.c
index 751b0e5336..6c65d5d8cb 100644
--- a/source3/lib/username.c
+++ b/source3/lib/username.c
@@ -23,8 +23,8 @@
extern int DEBUGLEVEL;
/* internal functions - modified versions of the ones in password.c */
-static struct passwd *uname_string_combinations(char *s, struct passwd * (*fn) (), int N);
-static struct passwd *uname_string_combinations2(char *s, int offset, struct passwd * (*fn) (), int N);
+static struct passwd *uname_string_combinations(char *s, struct passwd * (*fn) (char *), int N);
+static struct passwd *uname_string_combinations2(char *s, int offset, struct passwd * (*fn) (char *), int N);
/****************************************************************************
get a users home directory. tries as-is then lower case
@@ -288,7 +288,7 @@ try all combinations with N uppercase letters.
offset is the first char to try and change (start with 0)
it assumes the string starts lowercased
****************************************************************************/
-static struct passwd *uname_string_combinations2(char *s,int offset,struct passwd *(*fn)(),int N)
+static struct passwd *uname_string_combinations2(char *s,int offset,struct passwd *(*fn)(char *),int N)
{
int len = strlen(s);
int i;
@@ -322,7 +322,7 @@ try all combinations with up to N uppercase letters.
offset is the first char to try and change (start with 0)
it assumes the string starts lowercased
****************************************************************************/
-static struct passwd * uname_string_combinations(char *s,struct passwd * (*fn)(),int N)
+static struct passwd * uname_string_combinations(char *s,struct passwd * (*fn)(char *),int N)
{
int n;
struct passwd *ret;
diff --git a/source3/lib/util.c b/source3/lib/util.c
index 96cb86a1d8..2990a336c5 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -3721,7 +3721,7 @@ static BOOL matchname(char *remotehost,struct in_addr addr)
static BOOL global_client_name_done = False;
static BOOL global_client_addr_done = False;
-void reset_globals_after_fork()
+void reset_globals_after_fork(void)
{
global_client_name_done = False;
global_client_addr_done = False;
@@ -4621,7 +4621,7 @@ void set_remote_arch(enum remote_arch_types type)
/*******************************************************************
Get the remote_arch type.
********************************************************************/
-enum remote_arch_types get_remote_arch()
+enum remote_arch_types get_remote_arch(void)
{
return ra_type;
}
diff --git a/source3/libsmb/namequery.c b/source3/libsmb/namequery.c
index 8927522090..4de10f10ce 100644
--- a/source3/libsmb/namequery.c
+++ b/source3/libsmb/namequery.c
@@ -89,7 +89,7 @@ static void _interpret_node_status(char *p, char *master,char *rname)
**************************************************************************/
BOOL name_status(int fd,char *name,int name_type,BOOL recurse,
struct in_addr to_ip,char *master,char *rname,
- void (*fn)())
+ void (*fn)(struct packet_struct *))
{
BOOL found=False;
int retries = 2;
@@ -194,9 +194,8 @@ BOOL name_status(int fd,char *name,int name_type,BOOL recurse,
returns an array of IP addresses or NULL if none
*count will be set to the number of addresses returned
****************************************************************************/
-struct in_addr *name_query(int fd,char *name,int name_type,
- BOOL bcast,BOOL recurse,
- struct in_addr to_ip, int *count, void (*fn)())
+struct in_addr *name_query(int fd,char *name,int name_type, BOOL bcast,BOOL recurse,
+ struct in_addr to_ip, int *count, void (*fn)(struct packet_struct *))
{
BOOL found=False;
int i, retries = 3;
diff --git a/source3/nmbd/asyncdns.c b/source3/nmbd/asyncdns.c
index 3fb16a08e9..6019819793 100644
--- a/source3/nmbd/asyncdns.c
+++ b/source3/nmbd/asyncdns.c
@@ -110,7 +110,7 @@ static void asyncdns_process(void)
WINS db that our parent is going to write.
**************************************************************************** */
-static int sig_term()
+static int sig_term(void)
{
_exit(0);
/* Keep compiler happy.. */
@@ -122,7 +122,7 @@ static int sig_term()
child so we don't get child async dns processes lying around, causing trouble.
****************************************************************************/
-void kill_async_dns_child()
+void kill_async_dns_child(void)
{
if(child_pid != 0 && child_pid != -1)
kill(child_pid, SIGTERM);
@@ -342,7 +342,7 @@ BOOL queue_dns_query(struct packet_struct *p,struct nmb_name *question,
/***************************************************************************
With sync dns there is no child to kill on SIGTERM.
****************************************************************************/
-void kill_async_dns_child()
+void kill_async_dns_child(void)
{
return;
}
diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c
index 837f98e8bb..8373997e64 100644
--- a/source3/nmbd/nmbd.c
+++ b/source3/nmbd/nmbd.c
@@ -61,7 +61,7 @@ extern struct in_addr ipzero;
/**************************************************************************** **
catch a sigterm
**************************************************************************** */
-static int sig_term()
+static int sig_term(void)
{
BlockSignals(True,SIGTERM);
@@ -441,7 +441,7 @@ static BOOL open_sockets(BOOL isdaemon, int port)
/**************************************************************************** **
initialise connect, service and file structs
**************************************************************************** */
-static BOOL init_structs()
+static BOOL init_structs(void)
{
extern fstring local_machine;
char *p, *ptr;
@@ -577,7 +577,7 @@ int main(int argc,char *argv[])
argc--;
}
- fault_setup( fault_continue );
+ fault_setup((void (*)(void *))fault_continue );
signal( SIGHUP, SIGNAL_CAST sig_hup );
signal( SIGTERM, SIGNAL_CAST sig_term );
diff --git a/source3/nmbd/nmbd_mynames.c b/source3/nmbd/nmbd_mynames.c
index 30804ab807..cf21fafd87 100644
--- a/source3/nmbd/nmbd_mynames.c
+++ b/source3/nmbd/nmbd_mynames.c
@@ -49,7 +49,7 @@ static void my_name_register_failed(struct subnet_record *subrec,
Also add the magic Samba names.
**************************************************************************/
-BOOL register_my_workgroup_and_names()
+BOOL register_my_workgroup_and_names(void)
{
struct subnet_record *subrec;
struct work_record *work;
@@ -143,7 +143,7 @@ Exiting.\n", myworkgroup, subrec->subnet_name));
Remove all the names we registered.
**************************************************************************/
-void release_my_names()
+void release_my_names(void)
{
struct subnet_record *subrec;
diff --git a/source3/nmbd/nmbd_namelistdb.c b/source3/nmbd/nmbd_namelistdb.c
index 2237fc504d..b37cac10dc 100644
--- a/source3/nmbd/nmbd_namelistdb.c
+++ b/source3/nmbd/nmbd_namelistdb.c
@@ -551,7 +551,7 @@ static void dump_subnet_namelist( struct subnet_record *subrec, FILE *fp)
into a file. Initiated by SIGHUP - used to debug the state of the namelists.
**************************************************************************/
-void dump_all_namelists()
+void dump_all_namelists(void)
{
fstring fname;
FILE *fp;
diff --git a/source3/nmbd/nmbd_packets.c b/source3/nmbd/nmbd_packets.c
index cafed5f79a..19c61a877a 100644
--- a/source3/nmbd/nmbd_packets.c
+++ b/source3/nmbd/nmbd_packets.c
@@ -1488,7 +1488,7 @@ found for id = %hu. Ignoring packet.\n", nmb->header.name_trn_id));
Run elements off the packet queue till its empty
******************************************************************/
-void run_packet_queue()
+void run_packet_queue(void)
{
struct packet_struct *p;
diff --git a/source3/nmbd/nmbd_sendannounce.c b/source3/nmbd/nmbd_sendannounce.c
index e39e251496..48072650c2 100644
--- a/source3/nmbd/nmbd_sendannounce.c
+++ b/source3/nmbd/nmbd_sendannounce.c
@@ -372,7 +372,7 @@ static time_t announce_timer_last=0;
immediately.
****************************************************************************/
-void reset_announce_timer()
+void reset_announce_timer(void)
{
announce_timer_last = time(NULL) - (CHECK_TIME_MST_ANNOUNCE * 60);
}
diff --git a/source3/nmbd/nmbd_subnetdb.c b/source3/nmbd/nmbd_subnetdb.c
index e10ddc2c6a..d8e8dd4ab9 100644
--- a/source3/nmbd/nmbd_subnetdb.c
+++ b/source3/nmbd/nmbd_subnetdb.c
@@ -164,7 +164,7 @@ for port %d. Error was %s\n", inet_ntoa(myip), DGRAM_PORT, strerror(errno)));
Create subnet entries.
**************************************************************************/
-BOOL create_subnets()
+BOOL create_subnets(void)
{
int num_interfaces = iface_count();
int i;
@@ -265,7 +265,7 @@ BOOL create_subnets()
Function to tell us if we can use the unicast subnet.
******************************************************************/
-BOOL we_are_a_wins_client()
+BOOL we_are_a_wins_client(void)
{
static int cache_we_are_a_wins_client = -1;
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index da9d2f77a5..da75b58d55 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -1739,7 +1739,7 @@ BOOL lp_do_parameter(int snum, char *pszParmName, char *pszParmValue)
/* if it is a special case then go ahead */
if (parm_table[parmnum].special) {
- parm_table[parmnum].special(pszParmValue,parm_ptr);
+ parm_table[parmnum].special(pszParmValue,(char **)parm_ptr);
return(True);
}
diff --git a/source3/passdb/smbpass.c b/source3/passdb/smbpass.c
index 0c5c290299..512d26c552 100644
--- a/source3/passdb/smbpass.c
+++ b/source3/passdb/smbpass.c
@@ -28,7 +28,7 @@ static char s_readbuf[16 * 1024];
Signal function to tell us we timed out.
****************************************************************/
-static void gotalarm_sig()
+static void gotalarm_sig(void)
{
gotalarm = 1;
}
diff --git a/source3/printing/pcap.c b/source3/printing/pcap.c
index 38c4dec3fc..0b3ad2b136 100644
--- a/source3/printing/pcap.c
+++ b/source3/printing/pcap.c
@@ -313,7 +313,7 @@ BOOL pcap_printername_ok(char *pszPrintername, char *pszPrintcapname)
run a function on each printer name in the printcap file. The function is
passed the primary name and the comment (if possible)
***************************************************************************/
-void pcap_printer_fn(void (*fn)())
+void pcap_printer_fn(void (*fn)(char *, char *))
{
pstring name,comment;
char *line;
diff --git a/source3/printing/print_svid.c b/source3/printing/print_svid.c
index cfdb0f1c34..f2126f25ac 100644
--- a/source3/printing/print_svid.c
+++ b/source3/printing/print_svid.c
@@ -45,7 +45,7 @@ typedef struct printer {
} printer_t;
static printer_t *printers = NULL;
-static void populate_printers()
+static void populate_printers(void)
{
FILE *fp;
@@ -88,7 +88,7 @@ static void populate_printers()
* names longer than 8 characters appear to work with my test
* clients (Win95/NT).
*/
-void sysv_printer_fn(void (*fn)())
+void sysv_printer_fn(void (*fn)(char *, char *))
{
printer_t *tmp;
diff --git a/source3/smbd/ipc.c b/source3/smbd/ipc.c
index 62951219bf..e4ddcbec69 100644
--- a/source3/smbd/ipc.c
+++ b/source3/smbd/ipc.c
@@ -3447,37 +3447,37 @@ struct
{
char *name;
int id;
- BOOL (*fn)();
+ BOOL (*fn)(int,uint16,char *,char *,int,int,char **,char **,int *,int *);
int flags;
} api_commands[] = {
- {"RNetShareEnum", 0, (BOOL (*)())api_RNetShareEnum,0},
- {"RNetShareGetInfo", 1, (BOOL (*)())api_RNetShareGetInfo,0},
- {"RNetServerGetInfo", 13, (BOOL (*)())api_RNetServerGetInfo,0},
- {"RNetGroupGetUsers", 52, (BOOL (*)())api_RNetGroupGetUsers,0},
- {"RNetUserGetInfo", 56, (BOOL (*)())api_RNetUserGetInfo,0},
- {"NetUserGetGroups", 59, (BOOL (*)())api_NetUserGetGroups,0},
- {"NetWkstaGetInfo", 63, (BOOL (*)())api_NetWkstaGetInfo,0},
- {"DosPrintQEnum", 69, (BOOL (*)())api_DosPrintQEnum,0},
- {"DosPrintQGetInfo", 70, (BOOL (*)())api_DosPrintQGetInfo,0},
- {"WPrintJobEnumerate",76, (BOOL (*)())api_WPrintJobEnumerate,0},
- {"WPrintJobGetInfo", 77, (BOOL (*)())api_WPrintJobGetInfo,0},
- {"RDosPrintJobDel", 81, (BOOL (*)())api_RDosPrintJobDel,0},
- {"RDosPrintJobPause", 82, (BOOL (*)())api_RDosPrintJobDel,0},
- {"RDosPrintJobResume",83, (BOOL (*)())api_RDosPrintJobDel,0},
- {"WPrintDestEnum", 84, (BOOL (*)())api_WPrintDestEnum,0},
- {"WPrintDestGetInfo", 85, (BOOL (*)())api_WPrintDestGetInfo,0},
- {"NetRemoteTOD", 91, (BOOL (*)())api_NetRemoteTOD,0},
- {"WPrintQueuePurge", 103, (BOOL (*)())api_WPrintQueuePurge,0},
- {"NetServerEnum", 104, (BOOL (*)())api_RNetServerEnum,0},
- {"WAccessGetUserPerms",105, (BOOL (*)())api_WAccessGetUserPerms,0},
- {"SetUserPassword", 115, (BOOL (*)())api_SetUserPassword,0},
- {"WWkstaUserLogon", 132, (BOOL (*)())api_WWkstaUserLogon,0},
- {"PrintJobInfo", 147, (BOOL (*)())api_PrintJobInfo,0},
- {"WPrintDriverEnum", 205, (BOOL (*)())api_WPrintDriverEnum,0},
- {"WPrintQProcEnum", 206, (BOOL (*)())api_WPrintQProcEnum,0},
- {"WPrintPortEnum", 207, (BOOL (*)())api_WPrintPortEnum,0},
- {"SamOEMChangePassword", 214, (BOOL (*)())api_SamOEMChangePassword,0},
- {NULL, -1, (BOOL (*)())api_Unsupported,0}};
+ {"RNetShareEnum", 0, api_RNetShareEnum,0},
+ {"RNetShareGetInfo", 1, api_RNetShareGetInfo,0},
+ {"RNetServerGetInfo", 13, api_RNetServerGetInfo,0},
+ {"RNetGroupGetUsers", 52, api_RNetGroupGetUsers,0},
+ {"RNetUserGetInfo", 56, api_RNetUserGetInfo,0},
+ {"NetUserGetGroups", 59, api_NetUserGetGroups,0},
+ {"NetWkstaGetInfo", 63, api_NetWkstaGetInfo,0},
+ {"DosPrintQEnum", 69, api_DosPrintQEnum,0},
+ {"DosPrintQGetInfo", 70, api_DosPrintQGetInfo,0},
+ {"WPrintJobEnumerate",76, api_WPrintJobEnumerate,0},
+ {"WPrintJobGetInfo", 77, api_WPrintJobGetInfo,0},
+ {"RDosPrintJobDel", 81, api_RDosPrintJobDel,0},
+ {"RDosPrintJobPause", 82, api_RDosPrintJobDel,0},
+ {"RDosPrintJobResume",83, api_RDosPrintJobDel,0},
+ {"WPrintDestEnum", 84, api_WPrintDestEnum,0},
+ {"WPrintDestGetInfo", 85, api_WPrintDestGetInfo,0},
+ {"NetRemoteTOD", 91, api_NetRemoteTOD,0},
+ {"WPrintQueuePurge", 103, api_WPrintQueuePurge,0},
+ {"NetServerEnum", 104, api_RNetServerEnum,0},
+ {"WAccessGetUserPerms",105, api_WAccessGetUserPerms,0},
+ {"SetUserPassword", 115, api_SetUserPassword,0},
+ {"WWkstaUserLogon", 132, api_WWkstaUserLogon,0},
+ {"PrintJobInfo", 147, api_PrintJobInfo,0},
+ {"WPrintDriverEnum", 205, api_WPrintDriverEnum,0},
+ {"WPrintQProcEnum", 206, api_WPrintQProcEnum,0},
+ {"WPrintPortEnum", 207, api_WPrintPortEnum,0},
+ {"SamOEMChangePassword", 214, api_SamOEMChangePassword,0},
+ {NULL, -1, api_Unsupported,0}};
/****************************************************************************
diff --git a/source3/smbd/message.c b/source3/smbd/message.c
index 8c3f6f6630..24477f31ff 100644
--- a/source3/smbd/message.c
+++ b/source3/smbd/message.c
@@ -90,7 +90,7 @@ static void msg_deliver(void)
/****************************************************************************
reply to a sends
****************************************************************************/
-int reply_sends(char *inbuf,char *outbuf)
+int reply_sends(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int len;
char *orig,*dest,*msg;
@@ -128,7 +128,7 @@ int reply_sends(char *inbuf,char *outbuf)
/****************************************************************************
reply to a sendstrt
****************************************************************************/
-int reply_sendstrt(char *inbuf,char *outbuf)
+int reply_sendstrt(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
char *orig,*dest;
int outsize = 0;
@@ -155,7 +155,7 @@ int reply_sendstrt(char *inbuf,char *outbuf)
/****************************************************************************
reply to a sendtxt
****************************************************************************/
-int reply_sendtxt(char *inbuf,char *outbuf)
+int reply_sendtxt(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int len;
int outsize = 0;
@@ -183,7 +183,7 @@ int reply_sendtxt(char *inbuf,char *outbuf)
/****************************************************************************
reply to a sendend
****************************************************************************/
-int reply_sendend(char *inbuf,char *outbuf)
+int reply_sendend(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = 0;
diff --git a/source3/smbd/password.c b/source3/smbd/password.c
index be032c5c38..74ebeb1617 100644
--- a/source3/smbd/password.c
+++ b/source3/smbd/password.c
@@ -819,7 +819,7 @@ try all combinations with N uppercase letters.
offset is the first char to try and change (start with 0)
it assumes the string starts lowercased
****************************************************************************/
-static BOOL string_combinations2(char *s,int offset,BOOL (*fn)(),int N)
+static BOOL string_combinations2(char *s,int offset,BOOL (*fn)(char *),int N)
{
int len = strlen(s);
int i;
@@ -850,7 +850,7 @@ try all combinations with up to N uppercase letters.
offset is the first char to try and change (start with 0)
it assumes the string starts lowercased
****************************************************************************/
-static BOOL string_combinations(char *s,BOOL (*fn)(),int N)
+static BOOL string_combinations(char *s,BOOL (*fn)(char *),int N)
{
int n;
for (n=1;n<=N;n++)
diff --git a/source3/smbd/predict.c b/source3/smbd/predict.c
index 862ba97f7e..6f6a4ca655 100644
--- a/source3/smbd/predict.c
+++ b/source3/smbd/predict.c
@@ -95,7 +95,7 @@ int read_predict(int fd,int offset,char *buf,char **ptr,int num)
/****************************************************************************
pre-read some data
****************************************************************************/
-void do_read_prediction()
+void do_read_prediction(void)
{
static int readsize = 0;
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index 8afda69b32..d4ee8223ad 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -217,7 +217,7 @@ static void parse_connect(char *p,char *service,char *user,
/****************************************************************************
reply to a tcon
****************************************************************************/
-int reply_tcon(char *inbuf,char *outbuf)
+int reply_tcon(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring service;
pstring user;
@@ -358,7 +358,7 @@ int reply_unknown(char *inbuf,char *outbuf)
/****************************************************************************
reply to an ioctl
****************************************************************************/
-int reply_ioctl(char *inbuf,char *outbuf)
+int reply_ioctl(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
DEBUG(3,("ignoring ioctl\n"));
#if 0
@@ -703,7 +703,7 @@ int reply_sesssetup_and_X(char *inbuf,char *outbuf,int length,int bufsize)
/****************************************************************************
reply to a chkpth
****************************************************************************/
-int reply_chkpth(char *inbuf,char *outbuf)
+int reply_chkpth(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = 0;
int cnum,mode;
@@ -758,7 +758,7 @@ int reply_chkpth(char *inbuf,char *outbuf)
/****************************************************************************
reply to a getatr
****************************************************************************/
-int reply_getatr(char *inbuf,char *outbuf)
+int reply_getatr(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring fname;
int cnum;
@@ -838,7 +838,7 @@ int reply_getatr(char *inbuf,char *outbuf)
/****************************************************************************
reply to a setatr
****************************************************************************/
-int reply_setatr(char *inbuf,char *outbuf)
+int reply_setatr(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring fname;
int cnum;
@@ -885,7 +885,7 @@ int reply_setatr(char *inbuf,char *outbuf)
/****************************************************************************
reply to a dskattr
****************************************************************************/
-int reply_dskattr(char *inbuf,char *outbuf)
+int reply_dskattr(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum;
int outsize = 0;
@@ -912,7 +912,7 @@ int reply_dskattr(char *inbuf,char *outbuf)
reply to a search
Can be called from SMBsearch, SMBffirst or SMBfunique.
****************************************************************************/
-int reply_search(char *inbuf,char *outbuf)
+int reply_search(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring mask;
pstring directory;
@@ -1158,7 +1158,7 @@ int reply_search(char *inbuf,char *outbuf)
/****************************************************************************
reply to a fclose (stop directory search)
****************************************************************************/
-int reply_fclose(char *inbuf,char *outbuf)
+int reply_fclose(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum;
int outsize = 0;
@@ -1195,7 +1195,7 @@ int reply_fclose(char *inbuf,char *outbuf)
/****************************************************************************
reply to an open
****************************************************************************/
-int reply_open(char *inbuf,char *outbuf)
+int reply_open(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring fname;
int cnum;
@@ -1448,7 +1448,7 @@ int reply_ulogoffX(char *inbuf,char *outbuf,int length,int bufsize)
/****************************************************************************
reply to a mknew or a create
****************************************************************************/
-int reply_mknew(char *inbuf,char *outbuf)
+int reply_mknew(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring fname;
int cnum,com;
@@ -1538,7 +1538,7 @@ int reply_mknew(char *inbuf,char *outbuf)
/****************************************************************************
reply to a create temporary file
****************************************************************************/
-int reply_ctemp(char *inbuf,char *outbuf)
+int reply_ctemp(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring fname;
pstring fname2;
@@ -1638,7 +1638,7 @@ static BOOL can_delete(char *fname,int cnum,int dirtype)
/****************************************************************************
reply to a unlink
****************************************************************************/
-int reply_unlink(char *inbuf,char *outbuf)
+int reply_unlink(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = 0;
pstring name;
@@ -1743,7 +1743,7 @@ int reply_unlink(char *inbuf,char *outbuf)
/****************************************************************************
reply to a readbraw (core+ protocol)
****************************************************************************/
-int reply_readbraw(char *inbuf, char *outbuf)
+int reply_readbraw(char *inbuf, char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,maxcount,mincount,fnum;
int nread = 0;
@@ -1853,7 +1853,7 @@ int reply_readbraw(char *inbuf, char *outbuf)
/****************************************************************************
reply to a lockread (core+ protocol)
****************************************************************************/
-int reply_lockread(char *inbuf,char *outbuf)
+int reply_lockread(char *inbuf,char *outbuf, int dum_size, int dum_buffsiz)
{
int cnum,fnum;
int nread = -1;
@@ -1899,7 +1899,7 @@ int reply_lockread(char *inbuf,char *outbuf)
/****************************************************************************
reply to a read
****************************************************************************/
-int reply_read(char *inbuf,char *outbuf)
+int reply_read(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,numtoread,fnum;
int nread = 0;
@@ -1994,7 +1994,7 @@ int reply_read_and_X(char *inbuf,char *outbuf,int length,int bufsize)
/****************************************************************************
reply to a writebraw (core+ or LANMAN1.0 protocol)
****************************************************************************/
-int reply_writebraw(char *inbuf,char *outbuf)
+int reply_writebraw(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int nwritten=0;
int total_written=0;
@@ -2101,7 +2101,7 @@ int reply_writebraw(char *inbuf,char *outbuf)
/****************************************************************************
reply to a writeunlock (core+)
****************************************************************************/
-int reply_writeunlock(char *inbuf,char *outbuf)
+int reply_writeunlock(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,fnum;
int nwritten = -1;
@@ -2158,7 +2158,7 @@ int reply_writeunlock(char *inbuf,char *outbuf)
/****************************************************************************
reply to a write
****************************************************************************/
-int reply_write(char *inbuf,char *outbuf,int dum1,int dum2)
+int reply_write(char *inbuf,char *outbuf,int dum_size,int dum_buffsize)
{
int cnum,numtowrite,fnum;
int nwritten = -1;
@@ -2166,9 +2166,6 @@ int reply_write(char *inbuf,char *outbuf,int dum1,int dum2)
int startpos;
char *data;
- dum1 = dum2 = 0;
-
-
cnum = SVAL(inbuf,smb_tid);
fnum = GETFNUM(inbuf,smb_vwv0);
@@ -2276,7 +2273,7 @@ int reply_write_and_X(char *inbuf,char *outbuf,int length,int bufsize)
/****************************************************************************
reply to a lseek
****************************************************************************/
-int reply_lseek(char *inbuf,char *outbuf)
+int reply_lseek(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,fnum;
uint32 startpos;
@@ -2317,7 +2314,7 @@ int reply_lseek(char *inbuf,char *outbuf)
/****************************************************************************
reply to a flush
****************************************************************************/
-int reply_flush(char *inbuf,char *outbuf)
+int reply_flush(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum, fnum;
int outsize = set_message(outbuf,0,0,True);
@@ -2348,7 +2345,7 @@ int reply_flush(char *inbuf,char *outbuf)
/****************************************************************************
reply to a exit
****************************************************************************/
-int reply_exit(char *inbuf,char *outbuf)
+int reply_exit(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = set_message(outbuf,0,0,True);
DEBUG(3,("%s exit\n",timestring()));
@@ -2360,7 +2357,7 @@ int reply_exit(char *inbuf,char *outbuf)
/****************************************************************************
reply to a close
****************************************************************************/
-int reply_close(char *inbuf,char *outbuf)
+int reply_close(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int fnum,cnum;
int outsize = 0;
@@ -2406,7 +2403,7 @@ int reply_close(char *inbuf,char *outbuf)
/****************************************************************************
reply to a writeclose (Core+ protocol)
****************************************************************************/
-int reply_writeclose(char *inbuf,char *outbuf)
+int reply_writeclose(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,numtowrite,fnum;
int nwritten = -1;
@@ -2455,7 +2452,7 @@ int reply_writeclose(char *inbuf,char *outbuf)
/****************************************************************************
reply to a lock
****************************************************************************/
-int reply_lock(char *inbuf,char *outbuf)
+int reply_lock(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int fnum,cnum;
int outsize = set_message(outbuf,0,0,True);
@@ -2484,7 +2481,7 @@ int reply_lock(char *inbuf,char *outbuf)
/****************************************************************************
reply to a unlock
****************************************************************************/
-int reply_unlock(char *inbuf,char *outbuf)
+int reply_unlock(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int fnum,cnum;
int outsize = set_message(outbuf,0,0,True);
@@ -2513,7 +2510,7 @@ int reply_unlock(char *inbuf,char *outbuf)
/****************************************************************************
reply to a tdis
****************************************************************************/
-int reply_tdis(char *inbuf,char *outbuf)
+int reply_tdis(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum;
int outsize = set_message(outbuf,0,0,True);
@@ -2541,7 +2538,7 @@ int reply_tdis(char *inbuf,char *outbuf)
/****************************************************************************
reply to a echo
****************************************************************************/
-int reply_echo(char *inbuf,char *outbuf)
+int reply_echo(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum;
int smb_reverb = SVAL(inbuf,smb_vwv0);
@@ -2591,7 +2588,7 @@ int reply_echo(char *inbuf,char *outbuf)
/****************************************************************************
reply to a printopen
****************************************************************************/
-int reply_printopen(char *inbuf,char *outbuf)
+int reply_printopen(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring fname;
pstring fname2;
@@ -2658,7 +2655,7 @@ int reply_printopen(char *inbuf,char *outbuf)
/****************************************************************************
reply to a printclose
****************************************************************************/
-int reply_printclose(char *inbuf,char *outbuf)
+int reply_printclose(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int fnum,cnum;
int outsize = set_message(outbuf,0,0,True);
@@ -2683,7 +2680,7 @@ int reply_printclose(char *inbuf,char *outbuf)
/****************************************************************************
reply to a printqueue
****************************************************************************/
-int reply_printqueue(char *inbuf,char *outbuf)
+int reply_printqueue(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum;
int outsize = set_message(outbuf,2,3,True);
@@ -2777,7 +2774,7 @@ int reply_printqueue(char *inbuf,char *outbuf)
/****************************************************************************
reply to a printwrite
****************************************************************************/
-int reply_printwrite(char *inbuf,char *outbuf)
+int reply_printwrite(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,numtowrite,fnum;
int outsize = set_message(outbuf,0,0,True);
@@ -2809,7 +2806,7 @@ int reply_printwrite(char *inbuf,char *outbuf)
/****************************************************************************
reply to a mkdir
****************************************************************************/
-int reply_mkdir(char *inbuf,char *outbuf)
+int reply_mkdir(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring directory;
int cnum;
@@ -2904,7 +2901,7 @@ static BOOL recursive_rmdir(char *directory)
/****************************************************************************
reply to a rmdir
****************************************************************************/
-int reply_rmdir(char *inbuf,char *outbuf)
+int reply_rmdir(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
pstring directory;
int cnum;
@@ -3096,7 +3093,7 @@ static BOOL can_rename(char *fname,int cnum)
/****************************************************************************
reply to a mv
****************************************************************************/
-int reply_mv(char *inbuf,char *outbuf)
+int reply_mv(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = 0;
pstring name;
@@ -3351,7 +3348,7 @@ static BOOL copy_file(char *src,char *dest1,int cnum,int ofun,
/****************************************************************************
reply to a file copy.
****************************************************************************/
-int reply_copy(char *inbuf,char *outbuf)
+int reply_copy(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = 0;
pstring name;
@@ -3485,7 +3482,7 @@ int reply_copy(char *inbuf,char *outbuf)
/****************************************************************************
reply to a setdir
****************************************************************************/
-int reply_setdir(char *inbuf,char *outbuf)
+int reply_setdir(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,snum;
int outsize = 0;
@@ -3714,7 +3711,7 @@ int reply_readbmpx(char *inbuf,char *outbuf,int length,int bufsize)
/****************************************************************************
reply to a SMBwritebmpx (write block multiplex primary) request
****************************************************************************/
-int reply_writebmpx(char *inbuf,char *outbuf)
+int reply_writebmpx(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,numtowrite,fnum;
int nwritten = -1;
@@ -3807,7 +3804,7 @@ int reply_writebmpx(char *inbuf,char *outbuf)
/****************************************************************************
reply to a SMBwritebs (write block multiplex secondary) request
****************************************************************************/
-int reply_writebs(char *inbuf,char *outbuf)
+int reply_writebs(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,numtowrite,fnum;
int nwritten = -1;
@@ -3888,7 +3885,7 @@ int reply_writebs(char *inbuf,char *outbuf)
/****************************************************************************
reply to a SMBsetattrE
****************************************************************************/
-int reply_setattrE(char *inbuf,char *outbuf)
+int reply_setattrE(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,fnum;
struct utimbuf unix_times;
@@ -3941,7 +3938,7 @@ not setting timestamps of 0\n",
/****************************************************************************
reply to a SMBgetattrE
****************************************************************************/
-int reply_getattrE(char *inbuf,char *outbuf)
+int reply_getattrE(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int cnum,fnum;
struct stat sbuf;
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index e0652d35c8..7216ae79bb 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -1060,7 +1060,7 @@ static file_fd_struct *fd_get_already_open(struct stat *sbuf)
fd support routines - attempt to find a empty slot in the FileFd array.
Increments the ref_count of the returned entry.
****************************************************************************/
-static file_fd_struct *fd_get_new()
+static file_fd_struct *fd_get_new(void)
{
int i;
file_fd_struct *fd_ptr;
@@ -2380,7 +2380,7 @@ int error_packet(char *inbuf,char *outbuf,int error_class,uint32 error_code,int
/****************************************************************************
this prevents zombie child processes
****************************************************************************/
-static int sig_cld()
+static int sig_cld(void)
{
static int depth = 0;
if (depth != 0)
@@ -2425,7 +2425,7 @@ static int sig_cld()
/****************************************************************************
this is called when the client exits abruptly
**************************************************************************/
-static int sig_pipe()
+static int sig_pipe(void)
{
struct cli_state *cli;
BlockSignals(True,SIGPIPE);
@@ -2698,7 +2698,7 @@ static void process_smb(char *inbuf, char *outbuf)
/****************************************************************************
open the oplock IPC socket communication
****************************************************************************/
-static BOOL open_oplock_ipc()
+static BOOL open_oplock_ipc(void)
{
struct sockaddr_in sock_name;
int len = sizeof(sock_name);
@@ -3318,7 +3318,7 @@ BOOL reload_services(BOOL test)
/****************************************************************************
this prevents zombie child processes
****************************************************************************/
-static int sig_hup()
+static int sig_hup(void)
{
BlockSignals(True,SIGHUP);
DEBUG(0,("Got SIGHUP\n"));
@@ -4066,7 +4066,7 @@ struct {
/****************************************************************************
reply to a negprot
****************************************************************************/
-static int reply_negprot(char *inbuf,char *outbuf)
+static int reply_negprot(char *inbuf,char *outbuf, int dum_size, int dum_buffsize)
{
int outsize = set_message(outbuf,1,0,True);
int Index=0;
@@ -4392,7 +4392,7 @@ struct smb_message_struct
{
int code;
char *name;
- int (*fn)();
+ int (*fn)(char *, char *, int, int);
int flags;
#if PROFILING
unsigned long time;
@@ -5042,7 +5042,7 @@ static void usage(char *pname)
seteuid(0);
#endif
- fault_setup(exit_server);
+ fault_setup((void (*)(void *))exit_server);
signal(SIGTERM , SIGNAL_CAST dflt_sig);
/* we want total control over the permissions on created files,
diff --git a/source3/utils/make_printerdef.c b/source3/utils/make_printerdef.c
index 514773eb48..0c3cb633af 100644
--- a/source3/utils/make_printerdef.c
+++ b/source3/utils/make_printerdef.c
@@ -94,7 +94,7 @@ char *scan(char *chaine,char **entry)
return (value);
}
-void build_subdir()
+void build_subdir(void)
{
int i=0;
char *entry;