Marked functions in src/sdl/ taking no parameters with the void parameter.
authorDavid Griffith <dave@661.org>
Sun, 30 Apr 2023 23:52:46 +0000 (16:52 -0700)
committerDavid Griffith <dave@661.org>
Thu, 4 May 2023 06:13:14 +0000 (23:13 -0700)
src/sdl/generic.c
src/sdl/sf_fonts.c
src/sdl/sf_frotz.h
src/sdl/sf_ftype.c
src/sdl/sf_images.c
src/sdl/sf_osfdlg.c
src/sdl/sf_resource.c
src/sdl/sf_sig.c
src/sdl/sf_sound.c
src/sdl/sf_util.c
src/sdl/sf_video.c

index 01ef49800347872e0184d1523d5b049ed0fbf580..18e2cc5860a4e789d7f4295275d90357efc30cf2 100644 (file)
@@ -369,7 +369,7 @@ void gen_add_to_history(zchar * str)
 /**
  * Reset the view to the end of history.
  */
-void gen_history_reset()
+void gen_history_reset(void)
 {
        history_view = history_next;
 } /* gen_history_reset */
index 1d08e4ca89952e6321e0f7302e80bae7768b3d17..f5c5ef4b827a116325484f46d741ba1490ee2755 100644 (file)
@@ -483,7 +483,7 @@ static void setfontk(int k, SFONT * f)
 }
 
 
-static void cleanfonts()
+static void cleanfonts(void)
 {
        int i;
        for (i = 0; i < 8; i++)
@@ -493,13 +493,13 @@ static void cleanfonts()
 }
 
 
-SF_textsetting *sf_curtextsetting()
+SF_textsetting *sf_curtextsetting(void)
 {
        return &current;
 }
 
 
-void sf_pushtextsettings()
+void sf_pushtextsettings(void)
 {
        if (tsstackptr < MAXSTACK) {
                tsstack[tsstackptr] = current;
@@ -508,7 +508,7 @@ void sf_pushtextsettings()
 }
 
 
-void sf_poptextsettings()
+void sf_poptextsettings(void)
 {
        if (tsstackptr) {
                tsstackptr--;
@@ -868,7 +868,7 @@ SFONT *sf_VGA_SFONT;
 
 
 /* ensure a font loaded */
-void sf_initfonts()
+void sf_initfonts(void)
 {
        int i, j, size = 0;
        zbyte *cfont, *bmp;
index d29139c4ad8589306ad1fb9d57b84d91159862c5..5ace234f058ed8af73e2d58a296b631b22ae1765 100644 (file)
@@ -130,7 +130,7 @@ void sf_setgamma(double gamma);
 /* get pointer from cache */
 sf_picture *sf_getpic(int num);
 
-void sf_flushtext();
+void sf_flushtext(void);
 
 /* glyph */
 typedef struct {
@@ -185,7 +185,7 @@ int sf_GetProfileInt(const char *sect, const char *id, int def);
 double sf_GetProfileDouble(const char *sect, const char *id, double def);
 char *sf_GetProfileString(const char *sect, const char *id, char *def);
 
-void sf_readsettings();
+void sf_readsettings(void);
 
 zlong sf_GetColour(int colour);
 zlong sf_GetDefaultColour(bool fore);
index 4ed6032f91530abd4db9f4047fb518de998093bf..9414fad4259c2dff84fb3e30e9e35b4b7cee6e9a 100644 (file)
@@ -130,7 +130,7 @@ static int hasglyph(SFONT * fo, zword c, int allowdef)
 static int inited = 0, initerr = 0;
 static FT_Library library;
 
-static void libfinish()
+static void libfinish(void)
 {
        if (!inited)
                return;
@@ -139,7 +139,7 @@ static void libfinish()
 } /* libfinish */
 
 
-static void libinit()
+static void libinit(void)
 {
        if (initerr)
                return;
@@ -340,7 +340,7 @@ SFONT *sf_loadftype(char *fspec, SFONT * like, int *err)
 
 /****************************************/
 
-void sf_initloader()
+void sf_initloader(void)
 {
        ttfontloader = sf_loadftype;
 } /* sf_initloader */
index 819a2e072aab154b71064595c9704d0891e146e2..36507387dea0ba9b766f6dcbef7e84eb9aa451a4 100644 (file)
@@ -422,7 +422,7 @@ static int sf_loadpic(int picture, sf_picture * graphic)
 static sf_picture cached[MAXCACHE];
 static int cacheinited = 0;
 
-static void cacheflush()
+static void cacheflush(void)
 {
        int i;
        if (!cacheinited)
@@ -437,7 +437,7 @@ static void cacheflush()
 } /* cacheflush */
 
 
-static void cacheinit()
+static void cacheinit(void)
 {
        int i;
        if (cacheinited)
index 6b10af1f0c924bee28f7e180fde35127759d36f3..82f80dc8fe0badc7fbdc962d27353a704c0193bd 100644 (file)
@@ -55,13 +55,13 @@ static int X, Y, W, H, xdlg, ydlg, wdlg, hdlg;
 #define HTEXT 18
 
 STATIC void cleanlist(ENTRY * t);
-STATIC void drawlist();
+STATIC void drawlist(void);
 STATIC ENTRY *dodir(char *dirname, char *pattern, char *resdir, int size,
                    int *ndirs, int *ntot);
 static int Numdirs, Numtot, First;
 static ENTRY *curdir = NULL, *selected;
 
-STATIC void updatelist()
+STATIC void updatelist(void)
 {
        if (curdir)
                cleanlist(curdir);
@@ -72,10 +72,10 @@ STATIC void updatelist()
        drawlist();
 } /* updatelist */
 
-STATIC void goright();
-STATIC void goleft();
+STATIC void goright(void);
+STATIC void goleft(void);
 /* assumes a / at end */
-STATIC void goup()
+STATIC void goup(void)
 {
        char *p;
        if (strlen(lastdir) < 2)
@@ -929,7 +929,7 @@ STATIC void drawnames(int x, int y, int w, int h, ENTRY * files, int first,
 } /* drawnames */
 
 
-STATIC void drawlist()
+STATIC void drawlist(void)
 {
        BAREA *a = bareas + A_list, *b = bareas + A_dir;
 
@@ -941,7 +941,7 @@ STATIC void drawlist()
 } /* drawlist */
 
 
-STATIC void goright()
+STATIC void goright(void)
 {
        if (First + Nrows * Ncols > Numtot)
                return;
@@ -950,7 +950,7 @@ STATIC void goright()
 } /* goright */
 
 
-STATIC void goleft()
+STATIC void goleft(void)
 {
        if (!First)
                return;
index 211ae7fe47911e22251b5c899e3904241340109b..4927192e635907ca67bdaed40b53920801619cb1 100644 (file)
@@ -85,7 +85,7 @@ bool m_adaptiveMode = FALSE;
 
 bb_resolution_t *reso;
 
-static void checkwidths()
+static void checkwidths(void)
 {
        reso = bb_get_resolution(blorb_map);
        if (reso) {
@@ -217,7 +217,7 @@ FILE *os_path_open(const char *name, const char *mode)
                return fp;
        }
        return NULL;    /* give up */
-} /* os_path_open() */
+} /* os_path_open */
 
 
 /*
@@ -366,7 +366,7 @@ void os_restart_game(int stage)
 #define DEFAULT_GAMMA 2.2
 double m_gamma = DEFAULT_GAMMA;
 
-void sf_initcolours()
+void sf_initcolours(void)
 {
        int i;
 
@@ -802,7 +802,7 @@ void os_fatal(const char *s, ...)
 
 
 /* If true, running one of Infocom's V6 games */
-bool sf_IsInfocomV6()
+bool sf_IsInfocomV6(void)
 {
        switch (story_id) {
        case ARTHUR:
@@ -1005,7 +1005,7 @@ static void cleanLLENTRY(LLENTRY * e)
 } /* cleanLLENTRY */
 
 
-static void cleanlocallist()
+static void cleanlocallist(void)
 {
        cleanLLENTRY(Lpics);
        Lpics = NULL;
index a41cde2e2b7bc9a507efa34b448f8bdb78282350..f33ac19baf18e1f829a51979ad2ebaaaad4cf51e 100644 (file)
@@ -30,7 +30,7 @@
 
 #ifdef WIN32
 
-static void resethandlers()
+static void resethandlers(void)
 {
        signal(SIGINT, SIG_DFL);
        signal(SIGFPE, SIG_DFL);
@@ -60,7 +60,7 @@ static void myhandler(int s)
 } /* myhandler */
 
 
-void sf_installhandlers()
+void sf_installhandlers(void)
 {
        signal(SIGINT, myhandler);
        signal(SIGFPE, myhandler);
@@ -150,7 +150,7 @@ static void bt_sighandler(int sig, siginfo_t * info, void *secret)
 } /* bt_sighandler */
 
 
-void sf_installhandlers()
+void sf_installhandlers(void)
 {
 
        /* Install our signal handler */
index dc3e9ccc2326f5d072aa717294851645d13965a4..5316bd1c9447e4396a13d7acd6368eef5bfe4715 100644 (file)
@@ -73,7 +73,7 @@ static int audio_buffers = 512;
 static Uint16 audio_format;
 static int bits;
 
-static void finishaudio()
+static void finishaudio(void)
 {
        if (!SFaudiorunning)
                return;
@@ -100,12 +100,12 @@ static void channel_finished(int channel);
  * whether sound is desired and has no means for indicating whether sound is
  * available.  See sf_initsound for the real init.
  */
-void os_init_sound()
+void os_init_sound(void)
 {
 } /* os_init_sound */
 
 
-int sf_initsound()
+int sf_initsound(void)
 {
        if (SFaudiorunning)
                return 1;
@@ -186,7 +186,7 @@ static void channel_finished(int channel)
 } /* channel_finished */
 
 
-static void stopsample()
+static void stopsample(void)
 {
        if (!e_sfx)
                return;
@@ -198,7 +198,7 @@ static void stopsample()
 } /* stopsample */
 
 
-static void stopmodule()
+static void stopmodule(void)
 {
        if (!e_mod)
                return;
@@ -208,7 +208,7 @@ static void stopmodule()
 } /* stopmodule */
 
 
-static void startsample()
+static void startsample(void)
 {
        if (!e_sfx)
                return;
@@ -218,7 +218,7 @@ static void startsample()
 } /* startsample */
 
 
-static void startmodule()
+static void startmodule(void)
 {
        if (!e_mod)
                return;
@@ -436,7 +436,7 @@ void os_stop_sample(int number)
 } /* os_stop_sample */
 
 
-void sf_checksound()
+void sf_checksound(void)
 {
        if ((e_sfx) && (e_sfx->ended)) {
                e_sfx->ended = 0;
index 33849fd824e8f9d172ac3fc85aeccc9ad6b08a2f..068cda21249919bead5e20d0c09ab2d4bd755398 100644 (file)
@@ -75,7 +75,7 @@ void sf_regcleanfunc(void *f, const char *p)
 } /* sf_regcleanfunc */
 
 
-void sf_cleanup_all()
+void sf_cleanup_all(void)
 {
        while (cflist) {
                cfrec *n = cflist->next;
@@ -840,7 +840,7 @@ static int dialog_read_file_name(char *file_name, const char *default_name,
 
 static char *rc = NULL;
 
-void sf_FinishProfile()
+void sf_FinishProfile(void)
 {
        if (!rc)
                return;
index ea606981811f2f6f6929046c52e4f222a2c4906e..886be8ec288786dc456167a2b69f245a0442bc8f 100644 (file)
@@ -42,7 +42,7 @@ int m_timerinterval = 100;
 
 extern bool sdl_active;
 
-static void sf_quitconf();
+static void sf_quitconf(void);
 
 static bool ApplyPalette(sf_picture *);
 static zlong screen_palette[16];
@@ -91,7 +91,7 @@ static int mywcslen(zchar * b)
 } /* mywcslen */
 
 
-static void myGrefresh()
+static void myGrefresh(void)
 {
        SDL_RenderClear(renderer);
        SDL_RenderCopy(renderer, texture, NULL, NULL);
@@ -329,7 +329,7 @@ void sf_rect(zlong color, int x, int y, int w, int h)
 } /* sf_rect */
 
 
-void sf_flushtext()
+void sf_flushtext(void)
 {
        SF_textsetting *ts = sf_curtextsetting();
        ts->cx += ts->oh;
@@ -410,7 +410,7 @@ static void scroll(int x, int y, int w, int h, int n)
  * Update the display if contents have changed.
  * Return whether contents had changed, i.e., display was updated.
  */
-bool sf_flushdisplay()
+bool sf_flushdisplay(void)
 {
        if (dirty) {
                SDL_UpdateTexture(texture, NULL, sbuffer,
@@ -469,7 +469,7 @@ static Uint32 SDLCALL mytimer(Uint32 inter, void *parm)
 } /* mytimer */
 
 
-static void cleanvideo()
+static void cleanvideo(void)
 {
        if (timerid)
                SDL_RemoveTimer(timerid);
@@ -480,7 +480,7 @@ static void cleanvideo()
 #define GM 0x00ff00
 #define BM 0xff0000
 
-static void sf_toggle_fullscreen()
+static void sf_toggle_fullscreen(void)
 {
        if (SDL_SetWindowFullscreen
            (window, isfullscreen ? 0 : SDL_WINDOW_FULLSCREEN_DESKTOP))
@@ -1332,7 +1332,7 @@ void sf_videodata(zlong ** sb, int *sp, int *ew, int *eh)
 
 
 extern zword sf_yesnooverlay(int xc, int yc, char *t, int sr);
-static void sf_quitconf()
+static void sf_quitconf(void)
 {
        if (sf_yesnooverlay(ewidth / 2, eheight / 2, "Quit: are you sure?", 1)
            == ZC_RETURN) {
@@ -1344,7 +1344,7 @@ static void sf_quitconf()
 } /* sf_quitconf */
 
 
-void os_tick()
+void os_tick(void)
 {
        sf_checksound();
        if (SDL_AtomicSet(&SFticked, 0)) {