summaryrefslogtreecommitdiff
path: root/libports
diff options
context:
space:
mode:
authorFlavio Cruz <flaviocruz@gmail.com>2023-04-08 01:03:31 -0400
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2023-04-08 10:55:59 +0200
commita096270c77b1f6461a2ef58660ad9cfa9cbb32bb (patch)
treeb9c713ad70ae6705a1dfe6d76c35c0d918515d2e /libports
parent5de1b81f0bb24ba38d0a819bba9bd526863b5385 (diff)
Further modernize Hurd code by enforcing strict prototypes and no implicit function declarations.
Most of the changes land in one of these buckets: * Removed unused declarations. * Used (void) to represent no parameters instead of () which means an undeterminate number of parameters. * Included missing header files whenever necessary (stdlib.h, sys/mman.h, etc) * Typedefed function pointers to be able to fully declare the parameter types. * Added declarations of library functions that are used elsewhere (example is libps/ps.h). * Made functions static whenever they are only used in that file. * Forwarded declarations of some methods that were made static. Message-Id: <ZDD1o7/tVYeZew+G@jupiter.tail36e24.ts.net>
Diffstat (limited to 'libports')
-rw-r--r--libports/manage-multithread.c2
-rw-r--r--libports/ports.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/libports/manage-multithread.c b/libports/manage-multithread.c
index d42cf97a..d138092b 100644
--- a/libports/manage-multithread.c
+++ b/libports/manage-multithread.c
@@ -104,7 +104,7 @@ ports_manage_port_operations_multithread (struct port_bucket *bucket,
ports_demuxer_type demuxer,
int thread_timeout,
int global_timeout,
- void (*hook)())
+ void (*hook)(void))
{
/* totalthreads is the number of total threads created. nreqthreads
is the number of threads not currently servicing any client. The
diff --git a/libports/ports.h b/libports/ports.h
index 2d6f6a60..c0f0a22a 100644
--- a/libports/ports.h
+++ b/libports/ports.h
@@ -436,7 +436,7 @@ void ports_interrupt_rpcs (void *port);
/* If the current thread's rpc has been interrupted with
ports_interrupt_rpcs, return true (and clear the interrupted flag). */
-int ports_self_interrupted ();
+int ports_self_interrupted (void);
/* Add RPC to the list of rpcs that have been interrupted. */
void _ports_record_interruption (struct rpc_info *rpc);