diff options
author | rathann <rathann@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-02-09 14:08:03 +0000 |
---|---|---|
committer | rathann <rathann@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2006-02-09 14:08:03 +0000 |
commit | e7db4ccf1afbb6653ae1aae44b1c96c724361985 (patch) | |
tree | 9cc7321a75460de67bd0dae4e940b73439a1374b /libvo/vo_gl2.c | |
parent | 1f34ddefd2546a37c6efe4fcd9ea3f7627af4a5d (diff) | |
download | mpv-e7db4ccf1afbb6653ae1aae44b1c96c724361985.tar.bz2 mpv-e7db4ccf1afbb6653ae1aae44b1c96c724361985.tar.xz |
Patch by Stefan Huehner / stefan % huehner ! org \
patch replaces '()' for the correct '(void)' in function
declarations/prototypes which have no parameters. The '()' syntax tell
thats there is a variable list of arguments, so that the compiler cannot
check this. The extra CFLAG '-Wstrict-declarations' shows those cases.
Comments about a similar patch applied to ffmpeg:
That in C++ these mean the same, but in ANSI C the semantics are
different; function() is an (obsolete) K&R C style forward declaration,
it basically means that the function can have any number and any types
of parameters, effectively completely preventing the compiler from doing
any sort of type checking. -- Erik Slagter
Defining functions with unspecified arguments is allowed but bad.
With arguments unspecified the compiler can't report an error/warning
if the function is called with incorrect arguments. -- Måns Rullgård
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@17567 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo/vo_gl2.c')
-rw-r--r-- | libvo/vo_gl2.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libvo/vo_gl2.c b/libvo/vo_gl2.c index 6274cf27e9..6b5396a855 100644 --- a/libvo/vo_gl2.c +++ b/libvo/vo_gl2.c @@ -100,7 +100,7 @@ struct TexSquare int dirtyXoff, dirtyYoff, dirtyWidth, dirtyHeight; }; -static GLint getInternalFormat() +static GLint getInternalFormat(void) { #ifdef GL_WIN32 PIXELFORMATDESCRIPTOR pfd; @@ -150,7 +150,7 @@ static GLint getInternalFormat() return GL_RGB; } -static int initTextures() +static int initTextures(void) { struct TexSquare *tsq=0; GLfloat texpercx, texpercy; @@ -467,7 +467,7 @@ static void gl_set_antialias (int val) } -static void drawTextureDisplay () +static void drawTextureDisplay (void) { struct TexSquare *square = texgrid; int x, y/*, xoff=0, yoff=0, wd, ht*/; |