1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-18 19:49:40 +00:00

Fix two mismatches between function declaration and definition.

In both cases, function pointer arguments were inconsistently declared
and the result worked because of C's odd rules around function pointer
(de)references.  With a stricter compiler these fail to compile.

Reported by:	pfg@
Obtained from:	base r350049 by brooks@ from CheriBSD
MFH:		2019Q3
Differential Revision:	https://reviews.freebsd.org/D20964
This commit is contained in:
Cy Schubert 2019-08-15 02:21:57 +00:00
parent 88814962e8
commit 1199e9e38c
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=508980
3 changed files with 27 additions and 1 deletions

View File

@ -3,7 +3,7 @@
PORTNAME= am-utils
PORTVERSION= 6.2
PORTREVISION= 3
PORTREVISION= 4
PORTEPOCH= 1
CATEGORIES= sysutils net
MASTER_SITES= ftp://ftp.am-utils.org/pub/am-utils/ \

View File

@ -0,0 +1,13 @@
Index: amd/amd.h
===================================================================
--- amd/amd.h (revision 350048)
+++ amd/amd.h (revision 350049)
@@ -625,7 +625,7 @@
extern void mapc_add_kv(mnt_map *, char *, char *);
extern mnt_map *mapc_find(char *, char *, const char *, const char *);
extern void mapc_free(opaque_t);
-extern int mapc_keyiter(mnt_map *, key_fun, opaque_t);
+extern int mapc_keyiter(mnt_map *, key_fun *, opaque_t);
extern void mapc_reload(void);
extern int mapc_search(mnt_map *, char *, char **);
extern void mapc_showtypes(char *buf, size_t l);

View File

@ -0,0 +1,13 @@
Index: amd/rpc_fwd.c
===================================================================
--- amd/rpc_fwd.c (revision 350048)
+++ amd/rpc_fwd.c (revision 350049)
@@ -221,7 +221,7 @@
* different address.
*/
int
-fwd_packet(int type_id, char *pkt, int len, struct sockaddr_in *fwdto, struct sockaddr_in *replyto, opaque_t cb_arg, fwd_fun cb)
+fwd_packet(int type_id, char *pkt, int len, struct sockaddr_in *fwdto, struct sockaddr_in *replyto, opaque_t cb_arg, fwd_fun *cb)
{
rpc_forward *p;
u_int *pkt_int;