Mercurial > mplayer.hg
changeset 28232:8df85ad26746
Add missing 'void' keyword to parameterless function declarations.
author | diego |
---|---|
date | Mon, 05 Jan 2009 14:48:03 +0000 |
parents | 4e5ef09a3959 |
children | bfb8ccb245a9 |
files | TOOLS/fastmemcpybench.c TOOLS/realcodecs/14_4.c TOOLS/realcodecs/28_8.c TOOLS/realcodecs/cook.c TOOLS/realcodecs/drv2.c TOOLS/realcodecs/drv3.c TOOLS/realcodecs/drv4.c TOOLS/realcodecs/ra.c TOOLS/realcodecs/rv30.c TOOLS/realcodecs/sipr.c gui/mplayer/gtk/opts.c libmpdemux/demux_xmms.c libvo/gl_common.c libvo/mga_common.c libvo/vo_gif89a.c libvo/vo_s3fb.c libvo/vo_xvmc.c libvo/vo_xvr100.c loader/dshow/libwin32.h mp3lib/sr1.c mp3lib/test.c osdep/getch2-win.c osdep/timer-win2.c stream/cdinfo.c vidix/mga_vid.c vidix/sysdep/libdha_os2.c vidix/sysdep/libdha_win32.c |
diffstat | 27 files changed, 94 insertions(+), 84 deletions(-) [+] |
line wrap: on
line diff
--- a/TOOLS/fastmemcpybench.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/fastmemcpybench.c Mon Jan 05 14:48:03 2009 +0000 @@ -7,6 +7,8 @@ tested it. */ +/* According to Uoti this code is broken. */ + #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -28,8 +30,8 @@ static unsigned char* frame=NULL; static int f; -static int mga_init(){ - +static int mga_init(void) +{ f = open("/dev/mga_vid",O_RDWR); if(f == -1) { @@ -74,7 +76,8 @@ #endif // Returns current time in microseconds -static unsigned int GetTimer(){ +static unsigned int GetTimer(void) +{ struct timeval tv; struct timezone tz; // float s;
--- a/TOOLS/realcodecs/14_4.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/14_4.c Mon Jan 05 14:48:03 2009 +0000 @@ -44,7 +44,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -100,7 +100,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -115,11 +115,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/28_8.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/28_8.c Mon Jan 05 14:48:03 2009 +0000 @@ -44,7 +44,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -100,7 +100,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -115,11 +115,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/cook.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/cook.c Mon Jan 05 14:48:03 2009 +0000 @@ -56,7 +56,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -147,7 +147,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -162,11 +162,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/drv2.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/drv2.c Mon Jan 05 14:48:03 2009 +0000 @@ -48,7 +48,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -124,7 +124,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -139,11 +139,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/drv3.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/drv3.c Mon Jan 05 14:48:03 2009 +0000 @@ -48,7 +48,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -124,7 +124,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -139,11 +139,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/drv4.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/drv4.c Mon Jan 05 14:48:03 2009 +0000 @@ -50,7 +50,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -96,7 +96,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -111,11 +111,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/ra.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/ra.c Mon Jan 05 14:48:03 2009 +0000 @@ -55,7 +55,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -146,7 +146,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -161,11 +161,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/rv30.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/rv30.c Mon Jan 05 14:48:03 2009 +0000 @@ -58,7 +58,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -175,7 +175,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -190,11 +190,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/TOOLS/realcodecs/sipr.c Mon Jan 05 12:50:53 2009 +0000 +++ b/TOOLS/realcodecs/sipr.c Mon Jan 05 14:48:03 2009 +0000 @@ -73,7 +73,7 @@ void *handle=NULL; /* exits program when failure */ -void loadSyms() { +void loadSyms(void) { fputs("loadSyms()\n", stderr); if (!b_dlOpened) { char *error; @@ -169,7 +169,7 @@ } } -void closeDll() { +void closeDll(void) { if (handle) { b_dlOpened=0; dlclose(handle); @@ -184,11 +184,11 @@ struct timezone tz; struct timeval tv1, tv2; -void tic() { +void tic(void) { gettimeofday(&tv1, &tz); } -void toc() { +void toc(void) { long secs, usecs; gettimeofday(&tv2, &tz); secs=tv2.tv_sec-tv1.tv_sec;
--- a/gui/mplayer/gtk/opts.c Mon Jan 05 12:50:53 2009 +0000 +++ b/gui/mplayer/gtk/opts.c Mon Jan 05 14:48:03 2009 +0000 @@ -182,8 +182,8 @@ void ShowDXR3Config( void ); void HideDXR3Config( void ); #endif - void ShowAudioConfig(); - void HideAudioConfig(); + void ShowAudioConfig( void ); + void HideAudioConfig( void ); static gboolean prHScaler( GtkWidget * widget,GdkEventMotion * event,gpointer user_data ); static void prToggled( GtkToggleButton * togglebutton,gpointer user_data ); @@ -1499,7 +1499,7 @@ static GtkWidget *BAudioOk; static GtkWidget *BAudioCancel; -void ShowAudioConfig() { +void ShowAudioConfig( void ) { if (AudioConfig) gtkActive(AudioConfig); else AudioConfig = create_AudioConfig(); @@ -1532,7 +1532,7 @@ gtkSetLayer(AudioConfig); } -void HideAudioConfig() { +void HideAudioConfig( void ) { if (!AudioConfig) return; gtk_widget_hide(AudioConfig); gtk_widget_destroy(AudioConfig); @@ -1580,7 +1580,7 @@ } } -GtkWidget *create_AudioConfig() { +GtkWidget *create_AudioConfig( void ) { GList *items = NULL; GtkWidget *vbox; GtkWidget *table;
--- a/libmpdemux/demux_xmms.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libmpdemux/demux_xmms.c Mon Jan 05 14:48:03 2009 +0000 @@ -166,11 +166,11 @@ static int no_plugins=0; /* Dummy functions */ -static InputVisType input_get_vis_type(){return 0;} +static InputVisType input_get_vis_type(void){return 0;} static void input_add_vis_pcm(int time, AFormat fmt, int nch, int length, void *ptr){} static void input_set_info_text(char * text){} -char *xmms_get_gentitle_format(){ return ""; } +char *xmms_get_gentitle_format(void){ return ""; } /* Dummy functions END*/ static void input_set_info(char* title,int length, int rate, int freq, int nch) @@ -212,7 +212,7 @@ closedir(dir); } -static void init_plugins(){ +static void init_plugins(void) { char *home; no_plugins=0; @@ -227,7 +227,7 @@ init_plugins_from_dir(XMMS_INPUT_PLUGIN_DIR); } -static void cleanup_plugins(){ +static void cleanup_plugins(void) { while(no_plugins>0){ --no_plugins; mp_msg(MSGT_DEMUX, MSGL_INFO, MSGTR_MPDEMUX_XMMS_ClosingPlugin,
--- a/libvo/gl_common.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libvo/gl_common.c Mon Jan 05 14:48:03 2009 +0000 @@ -1522,7 +1522,7 @@ *context = 0; } -void swapGlBuffers() { +void swapGlBuffers(void) { HDC vo_hdc = GetDC(vo_w32_window); SwapBuffers(vo_hdc); ReleaseDC(vo_w32_window, vo_hdc);
--- a/libvo/mga_common.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libvo/mga_common.c Mon Jan 05 14:48:03 2009 +0000 @@ -208,7 +208,7 @@ } #ifndef VO_XMGA -static void mga_fullscreen() +static void mga_fullscreen(void) { uint32_t w,h; if ( !vo_fs ) {
--- a/libvo/vo_gif89a.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libvo/vo_gif89a.c Mon Jan 05 14:48:03 2009 +0000 @@ -244,7 +244,7 @@ } // we do not draw osd. -void draw_osd() {} +void draw_osd(void) {} // we do not handle events. static void check_events(void) {}
--- a/libvo/vo_s3fb.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libvo/vo_s3fb.c Mon Jan 05 14:48:03 2009 +0000 @@ -71,7 +71,7 @@ static char *inpage, *inpage0, *smem = NULL; static void (*alpha_func)(); -static void clear_screen(); +static void clear_screen(void); /* streams registers */ #define PSTREAM_CONTROL_REG 0x8180 @@ -116,7 +116,7 @@ } // enable S3 registers -int enable() { +int enable(void) { int fd; if (v) @@ -148,7 +148,7 @@ return 0; } -void disable() { +void disable(void) { if (v) { writecrtc(0x53, v->cr53); writecrtc(0x39, v->cr39); @@ -227,7 +227,7 @@ return offset; } -void yuv_off() { +void yuv_off(void) { writecrtc(0x67, readcrtc(0x67) & ~0xc); memset(v->mmio + 0x8180, 0, 0x80); OUTREG(0x81b8, 0x900); @@ -328,7 +328,7 @@ } } -static void clear_screen() +static void clear_screen(void) { if (inpage0) { int n;
--- a/libvo/vo_xvmc.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libvo/vo_xvmc.c Mon Jan 05 14:48:03 2009 +0000 @@ -117,8 +117,8 @@ static void xvmc_free(void); static void xvmc_clean_surfaces(void); -static int count_free_surfaces(); -static struct xvmc_render_state * find_free_surface(); +static int count_free_surfaces(void); +static struct xvmc_render_state * find_free_surface(void); static const vo_info_t info = { "XVideo Motion Compensation", @@ -175,7 +175,7 @@ return; } -static void deallocate_xvimage() +static void deallocate_xvimage(void) { #ifdef HAVE_SHM if ( Shmem_Flag ) @@ -699,7 +699,7 @@ assert(0); } -static void init_osd_yuv_pal(){ +static void init_osd_yuv_pal(void) { char * palette; int rez; int i,j; @@ -745,7 +745,7 @@ printf("vo_xvmc: XvMCClearSubpicture failed!\n"); } -static void OSD_init(){ +static void OSD_init(void) { unsigned short osd_height, osd_width; int rez; @@ -1201,7 +1201,7 @@ src_rndr->state &= ~MP_XVMC_STATE_OSD_SOURCE; } } -static int count_free_surfaces(){ +static int count_free_surfaces(void) { int i,num; num=0; for(i=0; i<number_of_surfaces; i++){ @@ -1212,7 +1212,7 @@ return num; } -static struct xvmc_render_state * find_free_surface(){ +static struct xvmc_render_state * find_free_surface(void) { int i,t; int stat; struct xvmc_render_state * visible_rndr;
--- a/libvo/vo_xvr100.c Mon Jan 05 12:50:53 2009 +0000 +++ b/libvo/vo_xvr100.c Mon Jan 05 14:48:03 2009 +0000 @@ -135,7 +135,7 @@ -void pfb_overlay_on() { +void pfb_overlay_on(void) { int h_inc, h_step, ecp_div; pfb_vregs[PFB_CLOCK_CNTL_INDEX] = (pfb_vregs[PFB_CLOCK_CNTL_INDEX] & ~0x0000003f) | 0x00000008; @@ -192,11 +192,11 @@ pfb_vregs[PFB_OV0_AUTO_FLIP_CNTL] = PFB_OV0_AUTO_FLIP_BUF0; } -void pfb_overlay_off() { +void pfb_overlay_off(void) { pfb_vregs[PFB_OV0_SCALE_CNTL] = 0; } -void center_overlay() { +void center_overlay(void) { if (pfb_xres > pfb_dstwidth) { pfb_wx0 = (pfb_xres - pfb_dstwidth) / 2; pfb_wx1 = pfb_wx0 + pfb_dstwidth; @@ -321,7 +321,7 @@ munmap(pfb_vregs, PFB_REGS_MMAPLEN); } -static uint32_t pfb_fullscreen() { +static uint32_t pfb_fullscreen(void) { if (!pfb_fs) { aspect(&pfb_dstwidth,&pfb_dstheight, A_ZOOM); pfb_fs = 1;
--- a/loader/dshow/libwin32.h Mon Jan 05 12:50:53 2009 +0000 +++ b/loader/dshow/libwin32.h Mon Jan 05 14:48:03 2009 +0000 @@ -17,7 +17,7 @@ typedef struct FatalError { FatalError(); - void PrintAll() {} + void PrintAll(void) {} }FatalError; */
--- a/mp3lib/sr1.c Mon Jan 05 12:50:53 2009 +0000 +++ b/mp3lib/sr1.c Mon Jan 05 14:48:03 2009 +0000 @@ -496,7 +496,7 @@ #if 0 -void MP3_Close(){ +void MP3_Close(void){ MP3_eof=1; if(mp3_file) fclose(mp3_file); mp3_file=NULL; @@ -565,7 +565,7 @@ #include "genre.h" // Read & print ID3 TAG. Do not call when playing!!! returns filesize. -int MP3_PrintTAG(){ +int MP3_PrintTAG(void){ struct id3tag { char tag[3]; char title[30];
--- a/mp3lib/test.c Mon Jan 05 12:50:53 2009 +0000 +++ b/mp3lib/test.c Mon Jan 05 14:48:03 2009 +0000 @@ -11,7 +11,7 @@ #include "mp3lib/mp3.h" #include "cpudetect.h" -static inline unsigned int GetTimer(){ +static inline unsigned int GetTimer(void){ struct timeval tv; struct timezone tz; // float s;
--- a/osdep/getch2-win.c Mon Jan 05 12:50:53 2009 +0000 +++ b/osdep/getch2-win.c Mon Jan 05 14:48:03 2009 +0000 @@ -29,7 +29,7 @@ int screen_height=24; char * erase_to_end_of_line = NULL; -void get_screen_size(){ +void get_screen_size(void){ } static HANDLE stdin; @@ -126,7 +126,8 @@ mplayer_put_key(r); } -void getch2_enable(){ +void getch2_enable(void) +{ DWORD retval; stdin = GetStdHandle(STD_INPUT_HANDLE); if(!GetNumberOfConsoleInputEvents(stdin,&retval)) @@ -137,7 +138,8 @@ else getch2_status=1; } -void getch2_disable(){ +void getch2_disable(void) +{ if(!getch2_status) return; // already disabled / never enabled getch2_status=0; }
--- a/osdep/timer-win2.c Mon Jan 05 12:50:53 2009 +0000 +++ b/osdep/timer-win2.c Mon Jan 05 14:48:03 2009 +0000 @@ -7,12 +7,14 @@ const char *timer_name = "Windows native"; // Returns current time in microseconds -unsigned int GetTimer(){ +unsigned int GetTimer(void) +{ return timeGetTime() * 1000; } // Returns current time in milliseconds -unsigned int GetTimerMS(){ +unsigned int GetTimerMS(voi) +{ return timeGetTime() ; } @@ -27,7 +29,8 @@ static DWORD RelativeTime = 0; -float GetRelativeTime(){ +float GetRelativeTime(void) +{ DWORD t, r; t = GetTimer(); r = t - RelativeTime; @@ -35,6 +38,7 @@ return (float) r *0.000001F; } -void InitTimer(){ +void InitTimer(void) +{ GetRelativeTime(); }
--- a/stream/cdinfo.c Mon Jan 05 12:50:53 2009 +0000 +++ b/stream/cdinfo.c Mon Jan 05 14:48:03 2009 +0000 @@ -20,7 +20,7 @@ *******************************************************************************************************************/ cd_info_t* -cd_info_new() { +cd_info_new(void) { cd_info_t *cd_info = NULL; cd_info = malloc(sizeof(cd_info_t));
--- a/vidix/mga_vid.c Mon Jan 05 12:50:53 2009 +0000 +++ b/vidix/mga_vid.c Mon Jan 05 14:48:03 2009 +0000 @@ -566,7 +566,8 @@ } #ifdef MGA_ALLOW_IRQ -static void enable_irq(){ +static void enable_irq(void) +{ long int cc; cc = readl(mga_mmio_base + IEN); @@ -582,7 +583,7 @@ return; } -static void disable_irq() +static void disable_irq(void) { writeb( 0x11, mga_mmio_base + CRTCX); writeb(0x20, mga_mmio_base + CRTCD ); /* clear 0, enable off */
--- a/vidix/sysdep/libdha_os2.c Mon Jan 05 12:50:53 2009 +0000 +++ b/vidix/sysdep/libdha_os2.c Mon Jan 05 14:48:03 2009 +0000 @@ -45,7 +45,7 @@ static HFILE mapdev = -1; static ULONG stored_virt_addr; static char* mappath = "\\DEV\\PMAP$"; -static HFILE open_mmap() +static HFILE open_mmap(void) { APIRET rc; ULONG action; @@ -62,7 +62,7 @@ return mapdev; } -static void close_mmap() +static void close_mmap(void) { if (mapdev != -1) DosClose(mapdev);
--- a/vidix/sysdep/libdha_win32.c Mon Jan 05 12:50:53 2009 +0000 +++ b/vidix/sysdep/libdha_win32.c Mon Jan 05 14:48:03 2009 +0000 @@ -33,7 +33,7 @@ #define METHOD_NEITHER 3 -int IsWinNT(){ +int IsWinNT(void) { OSVERSIONINFO OSVersionInfo; OSVersionInfo.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); GetVersionEx(&OSVersionInfo);