Patch 9.0.1471 Problem: Warnings for function declarations. Solution: Add argument types. (Michael Jarvis, closes #12277) Files: src/crypt.c, src/os_macosx.m, src/os_unix.c, src/proto/os_macosx.pro
*** ../vim-9.0.1470/src/crypt.c 2023-02-21 14:27:34.512360384 +0000 --- src/crypt.c 2023-04-19 20:22:04.562082780 +0100 *************** *** 40,46 **** int whole_undofile; // whole undo file is encrypted // Optional function pointer for a self-test. ! int (* self_test_fn)(); // Function pointer for initializing encryption/decryption. int (* init_fn)(cryptstate_T *state, char_u *key, --- 40,46 ---- int whole_undofile; // whole undo file is encrypted // Optional function pointer for a self-test. ! int (* self_test_fn)(void); // Function pointer for initializing encryption/decryption. int (* init_fn)(cryptstate_T *state, char_u *key, *** ../vim-9.0.1470/src/os_macosx.m 2022-11-02 13:30:37.534314540 +0000 --- src/os_macosx.m 2023-04-19 20:22:04.566082780 +0100 *************** *** 430,436 **** @end void ! process_cfrunloop() { if (sounds_list != nil && [sounds_list count] > 0) { --- 430,436 ---- @end void ! process_cfrunloop(void) { if (sounds_list != nil && [sounds_list count] > 0) { *************** *** 493,499 **** } void ! sound_mch_clear() { if (sounds_list != nil) { --- 493,499 ---- } void ! sound_mch_clear(void) { if (sounds_list != nil) { *************** *** 510,516 **** } void ! sound_mch_free() { sound_mch_clear(); } --- 510,516 ---- } void ! sound_mch_free(void) { sound_mch_clear(); } *** ../vim-9.0.1470/src/os_unix.c 2023-04-13 19:15:50.027391986 +0100 --- src/os_unix.c 2023-04-19 20:22:04.570082780 +0100 *************** *** 198,204 **** static void catch_int_signal(void); static void set_signals(void); ! static void catch_signals(void (*func_deadly)(), void (*func_other)()); #ifdef HAVE_SIGPROCMASK # define SIGSET_DECL(set) sigset_t set; # define BLOCK_SIGNALS(set) block_signals(set) --- 198,204 ---- static void catch_int_signal(void); static void set_signals(void); ! static void catch_signals(void (*func_deadly)(int), void (*func_other)(int)); #ifdef HAVE_SIGPROCMASK # define SIGSET_DECL(set) sigset_t set; # define BLOCK_SIGNALS(set) block_signals(set) *************** *** 668,676 **** // a patch from Sun to fix this. Reported by Gunnar Pedersen. select(0, NULL, NULL, NULL, &tv); } ! # endif // HAVE_SELECT ! # endif // HAVE_NANOSLEEP ! #endif // HAVE_USLEEP #ifdef FEAT_MZSCHEME } while (total > 0); --- 668,676 ---- // a patch from Sun to fix this. Reported by Gunnar Pedersen. select(0, NULL, NULL, NULL, &tv); } ! # endif ! # endif ! #endif #ifdef FEAT_MZSCHEME } while (total > 0); *************** *** 812,818 **** * Get a size of signal stack. * Preference (if available): sysconf > SIGSTKSZ > guessed size */ ! static long int get_signal_stack_size() { # ifdef HAVE_SYSCONF_SIGSTKSZ long int size = -1; --- 812,818 ---- * Get a size of signal stack. * Preference (if available): sysconf > SIGSTKSZ > guessed size */ ! static long int get_signal_stack_size(void) { # ifdef HAVE_SYSCONF_SIGSTKSZ long int size = -1; *************** *** 869,875 **** sig_winch SIGDEFARG(sigarg) { // this is not required on all systems, but it doesn't hurt anybody ! signal(SIGWINCH, (void (*)())sig_winch); do_resize = TRUE; } #endif --- 869,875 ---- sig_winch SIGDEFARG(sigarg) { // this is not required on all systems, but it doesn't hurt anybody ! signal(SIGWINCH, (void (*)(int))sig_winch); do_resize = TRUE; } #endif *************** *** 890,896 **** #if !defined(__ANDROID__) && !defined(__OpenBSD__) && !defined(__DragonFly__) // This is not required on all systems. On some systems (at least Android, // OpenBSD, and DragonFlyBSD) this breaks suspending with CTRL-Z. ! signal(SIGTSTP, (void (*)())sig_tstp); #endif } #endif --- 890,896 ---- #if !defined(__ANDROID__) && !defined(__OpenBSD__) && !defined(__DragonFly__) // This is not required on all systems. On some systems (at least Android, // OpenBSD, and DragonFlyBSD) this breaks suspending with CTRL-Z. ! signal(SIGTSTP, (void (*)(int))sig_tstp); #endif } #endif *************** *** 900,906 **** catch_sigint SIGDEFARG(sigarg) { // this is not required on all systems, but it doesn't hurt anybody ! signal(SIGINT, (void (*)())catch_sigint); got_int = TRUE; } #endif --- 900,906 ---- catch_sigint SIGDEFARG(sigarg) { // this is not required on all systems, but it doesn't hurt anybody ! signal(SIGINT, (void (*)(int))catch_sigint); got_int = TRUE; } #endif *************** *** 910,916 **** catch_sigusr1 SIGDEFARG(sigarg) { // this is not required on all systems, but it doesn't hurt anybody ! signal(SIGUSR1, (void (*)())catch_sigusr1); got_sigusr1 = TRUE; } #endif --- 910,916 ---- catch_sigusr1 SIGDEFARG(sigarg) { // this is not required on all systems, but it doesn't hurt anybody ! signal(SIGUSR1, (void (*)(int))catch_sigusr1); got_sigusr1 = TRUE; } #endif *************** *** 1383,1389 **** /* * WINDOW CHANGE signal is handled with sig_winch(). */ ! signal(SIGWINCH, (void (*)())sig_winch); #endif #ifdef SIGTSTP --- 1383,1389 ---- /* * WINDOW CHANGE signal is handled with sig_winch(). */ ! signal(SIGWINCH, (void (*)(int))sig_winch); #endif #ifdef SIGTSTP *************** *** 1395,1401 **** # ifdef FEAT_GUI : gui.in_use || gui.starting ? SIG_DFL # endif ! : (void (*)())sig_tstp); #endif #if defined(SIGCONT) signal(SIGCONT, sigcont_handler); --- 1395,1401 ---- # ifdef FEAT_GUI : gui.in_use || gui.starting ? SIG_DFL # endif ! : (void (*)(int))sig_tstp); #endif #if defined(SIGCONT) signal(SIGCONT, sigcont_handler); *************** *** 1415,1421 **** /* * Call user's handler on SIGUSR1 */ ! signal(SIGUSR1, (void (*)())catch_sigusr1); #endif /* --- 1415,1421 ---- /* * Call user's handler on SIGUSR1 */ ! signal(SIGUSR1, (void (*)(int))catch_sigusr1); #endif /* *************** *** 1454,1460 **** static void catch_int_signal(void) { ! signal(SIGINT, (void (*)())catch_sigint); } #endif --- 1454,1460 ---- static void catch_int_signal(void) { ! signal(SIGINT, (void (*)(int))catch_sigint); } #endif *************** *** 1470,1477 **** static void catch_signals( ! void (*func_deadly)(), ! void (*func_other)()) { int i; --- 1470,1477 ---- static void catch_signals( ! void (*func_deadly)(int), ! void (*func_other)(int)) { int i; *** ../vim-9.0.1470/src/proto/os_macosx.pro 2022-10-08 13:49:41.893378443 +0100 --- src/proto/os_macosx.pro 2023-04-19 20:22:04.574082780 +0100 *************** *** 1,7 **** /* os_macosx.m */ ! void process_cfrunloop(); bool sound_mch_play(const char_u* event, long sound_id, soundcb_T *callback, bool playfile); void sound_mch_stop(long sound_id); ! void sound_mch_clear(); ! void sound_mch_free(); /* vim: set ft=c : */ --- 1,7 ---- /* os_macosx.m */ ! void process_cfrunloop(void); bool sound_mch_play(const char_u* event, long sound_id, soundcb_T *callback, bool playfile); void sound_mch_stop(long sound_id); ! void sound_mch_clear(void); ! void sound_mch_free(void); /* vim: set ft=c : */ *** ../vim-9.0.1470/src/version.c 2023-04-19 14:21:19.082048665 +0100 --- src/version.c 2023-04-19 20:23:22.078085041 +0100 *************** *** 697,698 **** --- 697,700 ---- { /* Add new patch number below this line */ + /**/ + 1471, /**/ -- Dogs must have a permit signed by the mayor in order to congregate in groups of three or more on private property. [real standing law in Oklahoma, United States of America] /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org /// -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/vim_dev/20230419192914.E97BF1C0787%40moolenaar.net.