drm-tests: Fix warnings in null_platform_test
Fix some missing-prototypes and strict-prototypes warnings.
BUG=None
TEST=Local build with -Wall is now free of warnings
Change-Id: Ic892ea3bfcc35589bdc108eee744030468040e4d
Reviewed-on: https://chromium-review.googlesource.com/236740
Reviewed-by: Lauri Peltonen <lpeltonen@nvidia.com>
Commit-Queue: Lauri Peltonen <lpeltonen@nvidia.com>
Tested-by: Lauri Peltonen <lpeltonen@nvidia.com>
Reviewed-by: Stéphane Marchesin <marcheu@chromium.org>
diff --git a/null_platform_test.c b/null_platform_test.c
index 93a03c3..ea75696 100644
--- a/null_platform_test.c
+++ b/null_platform_test.c
@@ -24,7 +24,7 @@
#include <xf86drm.h>
#include <xf86drmMode.h>
-const char * get_gl_error()
+static const char * get_gl_error(void)
{
switch (glGetError()) {
case GL_NO_ERROR:
@@ -44,7 +44,7 @@
}
}
-const char * get_egl_error()
+static const char * get_egl_error(void)
{
switch (eglGetError()) {
case EGL_SUCCESS:
@@ -120,7 +120,7 @@
};
-bool setup_drm(struct context * ctx)
+static bool setup_drm(struct context * ctx)
{
int fd = ctx->drm_card_fd;
drmModeRes *resources = NULL;
@@ -194,7 +194,8 @@
return true;
}
-float f(int i) {
+static float f(int i)
+{
int a = i % 40;
int b = (i / 40) % 6;
switch (b) {
@@ -220,7 +221,7 @@
*waiting_for_flip = 0;
}
-void draw(struct context * ctx)
+static void draw(struct context * ctx)
{
int i;
const GLchar *vertexShaderStr =