Fix errors when compiling on newer compilers (prototype definitions fix)

This commit is contained in:
junepark678 authored and Nick Chan committed 2023-02-24 23:28:35 +08:00
1 parent df0c0f346d
commit fae5eaf07e
7 files changed
+19 -20

No files matched your search

+1 -1
View File
@@ -6,7 +6,7 @@
#define THE_PLUSH "Ploosh"
#define T void
#define R print_credits() {
#define R print_credits(void) {
#define O fprintf
#define U (
#define B stdout
+1 -1
View File
@@ -93,7 +93,7 @@ int subscribe_cmd(usbmuxd_event_cb_t device_event_cb, irecv_device_event_cb_t ir
return 0;
}
int unsubscribe_cmd()
int unsubscribe_cmd(void)
{
usbmuxd_events_unsubscribe(usbmuxdctx);
irecv_device_event_unsubscribe(irecvctx);
+1 -1
View File
@@ -30,7 +30,7 @@ char* ext_checkra1n = NULL;
#define tmpdir getenv("TMPDIR") == NULL ? "/tmp" : getenv("TMPDIR")
int exec_checkra1n() {
int exec_checkra1n(void) {
LOG(LOG_INFO, "About to execute checkra1n");
int fd, ret;
char* checkra1n_path = NULL;
+3 -3
View File
@@ -55,7 +55,7 @@ static bool set_locked_bool(bool* val, bool newval, pthread_mutex_t* mutex) {
return newval;
}
bool get_spin() {
bool get_spin(void) {
return get_locked_bool(&spin, &spin_mutex);
}
@@ -63,7 +63,7 @@ bool set_spin(bool newval) {
return set_locked_bool(&spin, newval, &spin_mutex);
}
bool get_found_pongo() {
bool get_found_pongo(void) {
return get_locked_bool(&found_pongo, &found_pongo_mutex);
}
@@ -71,7 +71,7 @@ bool set_found_pongo(bool val) {
return set_locked_bool(&found_pongo, val, &found_pongo_mutex);
}
uint64_t get_ecid_wait_for_dfu() {
uint64_t get_ecid_wait_for_dfu(void) {
LOG(LOG_VERBOSE5, "locking ecid wait for dfu mutex for get");
pthread_mutex_lock(&ecid_dfu_wait_mutex);
uint64_t ret = ecid_wait_for_dfu;
+1 -2
View File
@@ -16,7 +16,6 @@
#include <signal.h>
#include <pthread.h>
#include <inttypes.h>
#include <getopt.h>
#include <errno.h>
#include <spawn.h>
#include <sys/mman.h>
@@ -56,7 +55,7 @@ void thr_cleanup(void* ptr) {
*(int*)ptr = 0;
}
int build_checks() {
int build_checks(void) {
#if defined(__APPLE__)
#ifndef NO_CHECKRAIN
struct mach_header_64* c1_header = (struct mach_header_64*)&checkra1n[0];