We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b81b7e3 + 85610e7 commit 565479fCopy full SHA for 565479f
package/CHANGES
@@ -1,3 +1,10 @@
1
+ * alloc.h, buffer.c, buffer.h, buffer_get.c, buffer_put.c, buffer_write.c,
2
+ byte.h, check-socklog-unix.c, pathexec_env.c, select.h1, select.h2,
3
+ sig.c, sig.h, sig_catch.c, socklog-check.c, socklog-check.dist,
4
+ socklog.c, tryto.c, tryto.dist, uncat.c, uncat.dist, wait.h: fix build
5
+ with gcc15: in C23 f() means f(void), consequently signal handler
6
+ functions now are f(int), alloc_free() and byte_zero() parameters need
7
+ casts, buffer_unixwrite() removes "const" from parameter.
8
* package/README: update copyright notice.
9
* doc/configuration.html: replace links to daemontools faq with runit faq.
10
* doc/*: switch all cr.yp.to http links to https.
src/alloc.h
@@ -3,8 +3,8 @@
#ifndef ALLOC_H
#define ALLOC_H
-extern /*@null@*//*@out@*/char *alloc();
-extern void alloc_free();
-extern int alloc_re();
+extern /*@null@*//*@out@*/char *alloc(unsigned int);
+extern void alloc_free(char *);
+extern int alloc_re(char **,unsigned int,unsigned int);
#endif
src/buffer.c
@@ -2,7 +2,7 @@
#include "buffer.h"
-void buffer_init(buffer *s,int (*op)(),int fd,char *buf,unsigned int len)
+void buffer_init(buffer *s,int (*op)(int,char *,unsigned int),int fd,char *buf,unsigned int len)
{
s->x = buf;
s->fd = fd;
src/buffer.h
@@ -8,14 +8,14 @@ typedef struct buffer {
unsigned int p;
unsigned int n;
int fd;
11
- int (*op)();
+ int (*op)(int,char *,unsigned int);
12
} buffer;
13
14
#define BUFFER_INIT(op,fd,buf,len) { (buf), 0, (len), (fd), (op) }
15
#define BUFFER_INSIZE 8192
16
#define BUFFER_OUTSIZE 8192
17
18
-extern void buffer_init(buffer *,int (*)(),int,char *,unsigned int);
+extern void buffer_init(buffer *,int (*)(int,char *,unsigned int),int,char *,unsigned int);
19
20
extern int buffer_flush(buffer *);
21
extern int buffer_put(buffer *,const char *,unsigned int);
@@ -50,7 +50,7 @@ extern void buffer_seek(buffer *,unsigned int);
50
extern int buffer_copy(buffer *,buffer *);
51
52
extern int buffer_unixread(int,char *,unsigned int);
53
-extern int buffer_unixwrite(int,const char *,unsigned int);
+extern int buffer_unixwrite(int,char *,unsigned int);
54
55
extern buffer *buffer_0;
56
extern buffer *buffer_0small;
src/buffer_get.c
@@ -4,7 +4,7 @@
#include "byte.h"
#include "error.h"
-static int oneread(int (*op)(),int fd,char *buf,unsigned int len)
+static int oneread(int (*op)(int,char *,unsigned int),int fd,char *buf,unsigned int len)
int r;
src/buffer_put.c
@@ -5,7 +5,7 @@
-static int allwrite(int (*op)(),int fd,const char *buf,unsigned int len)
+static int allwrite(int (*op)(int,char *,unsigned int),int fd,const char *buf,unsigned int len)
int w;
src/buffer_write.c
@@ -3,7 +3,7 @@
#include <unistd.h>
-int buffer_unixwrite(int fd,const char *buf,unsigned int len)
+int buffer_unixwrite(int fd,char *buf,unsigned int len)
return write(fd,buf,len);
}
src/byte.h
@@ -3,12 +3,12 @@
#ifndef BYTE_H
#define BYTE_H
-extern unsigned int byte_chr();
-extern unsigned int byte_rchr();
-extern void byte_copy();
-extern void byte_copyr();
-extern int byte_diff();
-extern void byte_zero();
+extern unsigned int byte_chr(char *,unsigned int,int);
+extern unsigned int byte_rchr(char *,unsigned int,int);
+extern void byte_copy(char *,unsigned int,char *);
+extern void byte_copyr(char *,unsigned int,char *);
+extern int byte_diff(char *,unsigned int,char *);
+extern void byte_zero(char *,unsigned int);
#define byte_equal(s,n,t) (!byte_diff((s),(n),(t)))
src/check-socklog-unix.c
@@ -14,7 +14,7 @@ struct sockaddr_un sa;
int main() {
s =socket(AF_UNIX, SOCK_DGRAM, 0);
if (s == -1) strerr_die1sys(111, "fatal: unable to create socket: ");
- byte_zero(&sa, sizeof(sa));
+ byte_zero((char *)&sa, sizeof(sa));
sa.sun_family =AF_UNIX;
strcpy(sa.sun_path, "socklog.check.socket");
if (connect(s, (struct sockaddr *) &sa, sizeof(sa)) == -1)
src/pathexec_env.c
@@ -65,5 +65,5 @@ void pathexec(char *const *argv)
65
e[elen] = 0;
66
67
pathexec_run(*argv,argv,e);
68
- alloc_free(e);
+ alloc_free((char *)e);
69
0 commit comments