No longer disable E_OLD_STYLE_FUNC_DEF.
--- a/make/autoconf/flags-cflags.m4 Fri Mar 02 19:10:12 2018 +0100
+++ b/make/autoconf/flags-cflags.m4 Sat Mar 03 08:21:47 2018 +0100
@@ -193,7 +193,7 @@
WARNINGS_ENABLE_ALL_CFLAGS="-v -fd -xtransition"
WARNINGS_ENABLE_ALL_CXXFLAGS="+w +w2"
- DISABLED_WARNINGS_C="E_OLD_STYLE_FUNC_DECL E_OLD_STYLE_FUNC_DEF E_SEMANTICS_OF_OP_CHG_IN_ANSI_C E_NO_REPLACEMENT_IN_STRING"
+ DISABLED_WARNINGS_C="E_OLD_STYLE_FUNC_DECL E_SEMANTICS_OF_OP_CHG_IN_ANSI_C E_NO_REPLACEMENT_IN_STRING"
DISABLED_WARNINGS_CXX="inllargeuse doubunder notused wemptydecl wunreachable"
;;
gcc)
--- a/src/java.base/share/native/libjli/args.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/share/native/libjli/args.c Sat Mar 03 08:21:47 2018 +0100
@@ -94,7 +94,7 @@
firstAppArgIndex = hasJavaArgs ? 0: NOT_FOUND;
}
-int JLI_GetAppArgIndex() {
+int JLI_GetAppArgIndex(void) {
// Will be 0 for tools
return firstAppArgIndex;
}
--- a/src/java.base/share/native/libjli/java.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/share/native/libjli/java.c Sat Mar 03 08:21:47 2018 +0100
@@ -1814,7 +1814,7 @@
* user native application, the following property indicates the former.
*/
void
-SetJavaLauncherProp() {
+SetJavaLauncherProp(void) {
AddOption("-Dsun.java.launcher=SUN_STANDARD", NULL);
}
@@ -2171,7 +2171,7 @@
}
static void
-FreeKnownVMs()
+FreeKnownVMs(void)
{
int i;
for (i = 0; i < knownVMsCount; i++) {
@@ -2186,7 +2186,7 @@
* and image file names stored in environment variables
*/
void
-ShowSplashScreen()
+ShowSplashScreen(void)
{
const char *jar_name = getenv(SPLASH_JAR_ENV_ENTRY);
const char *file_name = getenv(SPLASH_FILE_ENV_ENTRY);
@@ -2251,31 +2251,31 @@
}
const char*
-GetFullVersion()
+GetFullVersion(void)
{
return _fVersion;
}
const char*
-GetProgramName()
+GetProgramName(void)
{
return _program_name;
}
const char*
-GetLauncherName()
+GetLauncherName(void)
{
return _launcher_name;
}
jboolean
-IsJavaArgs()
+IsJavaArgs(void)
{
return _is_java_args;
}
static jboolean
-IsWildCardEnabled()
+IsWildCardEnabled(void)
{
return _wc_enabled;
}
@@ -2321,7 +2321,7 @@
}
static void
-DumpState()
+DumpState(void)
{
if (!JLI_IsTraceLauncher()) return ;
printf("Launcher state:\n");
--- a/src/java.base/share/native/libjli/jli_util.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/share/native/libjli/jli_util.c Sat Mar 03 08:21:47 2018 +0100
@@ -100,7 +100,7 @@
}
void
-JLI_SetTraceLauncher()
+JLI_SetTraceLauncher(void)
{
if (getenv(JLDEBUG_ENV_ENTRY) != 0) {
_launcher_debug = JNI_TRUE;
@@ -109,7 +109,7 @@
}
jboolean
-JLI_IsTraceLauncher()
+JLI_IsTraceLauncher(void)
{
return _launcher_debug;
}
--- a/src/java.base/share/native/libjli/parse_manifest.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/share/native/libjli/parse_manifest.c Sat Mar 03 08:21:47 2018 +0100
@@ -660,7 +660,7 @@
* Specialized "free" function.
*/
void
-JLI_FreeManifest()
+JLI_FreeManifest(void)
{
if (manifest)
free(manifest);
--- a/src/java.base/share/native/libnet/net_util.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/share/native/libnet/net_util.c Sat Mar 03 08:21:47 2018 +0100
@@ -33,12 +33,12 @@
static int IPv6_available;
static int REUSEPORT_available;
-JNIEXPORT jint JNICALL ipv6_available()
+JNIEXPORT jint JNICALL ipv6_available(void)
{
return IPv6_available;
}
-JNIEXPORT jint JNICALL reuseport_available()
+JNIEXPORT jint JNICALL reuseport_available(void)
{
return REUSEPORT_available;
}
--- a/src/java.base/share/native/libzip/zip_util.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/share/native/libzip/zip_util.c Sat Mar 03 08:21:47 2018 +0100
@@ -161,7 +161,7 @@
* if could not be initialized.
*/
static jint
-InitializeZip()
+InitializeZip(void)
{
static jboolean inited = JNI_FALSE;
--- a/src/java.base/unix/native/jspawnhelper/jspawnhelper.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/jspawnhelper/jspawnhelper.c Sat Mar 03 08:21:47 2018 +0100
@@ -53,7 +53,7 @@
exit (1);
}
-void shutItDown() {
+void shutItDown(void) {
fprintf(stdout, "This command is not for general use and should ");
fprintf(stdout, "only be run as the result of a call to\n");
fprintf(stdout, "ProcessBuilder.start() or Runtime.exec() in a java ");
--- a/src/java.base/unix/native/libjava/TimeZone_md.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libjava/TimeZone_md.c Sat Mar 03 08:21:47 2018 +0100
@@ -480,7 +480,7 @@
* as an environment variable.
*/
static char *
-getPlatformTimeZoneID()
+getPlatformTimeZoneID(void)
{
char *tz = NULL;
FILE *fp;
@@ -577,7 +577,7 @@
* /usr/share/lib/zoneinfo/localtime under /usr/share/lib/zoneinfo/.
*/
static char *
-getSolarisDefaultZoneID() {
+getSolarisDefaultZoneID(void) {
char *tz = NULL;
struct stat statbuf;
size_t size;
@@ -876,7 +876,7 @@
#else
char *
-getGMTOffsetID()
+getGMTOffsetID(void)
{
time_t offset;
char sign, buf[32];
--- a/src/java.base/unix/native/libjava/childproc.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libjava/childproc.c Sat Mar 03 08:21:47 2018 +0100
@@ -129,7 +129,7 @@
}
int
-magicNumber() {
+magicNumber(void) {
return 43110;
}
--- a/src/java.base/unix/native/libjava/jdk_util_md.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libjava/jdk_util_md.c Sat Mar 03 08:21:47 2018 +0100
@@ -26,7 +26,7 @@
#include <dlfcn.h>
#include "jdk_util.h"
-int JDK_InitJvmHandle() {
+int JDK_InitJvmHandle(void) {
/* nop */
return 1;
}
--- a/src/java.base/unix/native/libjava/jni_util_md.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libjava/jni_util_md.c Sat Mar 03 08:21:47 2018 +0100
@@ -37,7 +37,7 @@
#define strerror_r(a, b, c) __xpg_strerror_r((a), (b), (c))
#endif
-void* getProcessHandle() {
+void* getProcessHandle(void) {
static void *procHandle = NULL;
if (procHandle != NULL) {
return procHandle;
--- a/src/java.base/unix/native/libjli/java_md_common.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libjli/java_md_common.c Sat Mar 03 08:21:47 2018 +0100
@@ -312,7 +312,7 @@
}
jboolean
-IsJavaw()
+IsJavaw(void)
{
/* noop on UNIX */
return JNI_FALSE;
@@ -346,13 +346,13 @@
}
StdArg
-*JLI_GetStdArgs()
+*JLI_GetStdArgs(void)
{
return NULL;
}
int
-JLI_GetStdArgc() {
+JLI_GetStdArgc(void) {
return 0;
}
--- a/src/java.base/unix/native/libjli/java_md_solinux.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libjli/java_md_solinux.c Sat Mar 03 08:21:47 2018 +0100
@@ -163,7 +163,7 @@
* execname accessor from other parts of platform dependent logic
*/
const char *
-GetExecName() {
+GetExecName(void) {
return execname;
}
@@ -720,7 +720,7 @@
}
}
-void SplashFreeLibrary() {
+void SplashFreeLibrary(void) {
if (hSplashLib) {
dlclose(hSplashLib);
hSplashLib = NULL;
@@ -777,7 +777,7 @@
/* Coarse estimation of number of digits assuming the worst case is a 64-bit pid. */
#define MAX_PID_STR_SZ 20
-void SetJavaLauncherPlatformProps() {
+void SetJavaLauncherPlatformProps(void) {
/* Linux only */
#ifdef __linux__
const char *substr = "-Dsun.java.launcher.pid=";
@@ -803,7 +803,7 @@
}
void
-RegisterThread()
+RegisterThread(void)
{
// stubbed out for windows and *nixes.
}
--- a/src/java.base/unix/native/libnet/DefaultProxySelector.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libnet/DefaultProxySelector.c Sat Mar 03 08:21:47 2018 +0100
@@ -113,7 +113,7 @@
static int use_gconf = 0;
-static int initGConf() {
+static int initGConf(void) {
/**
* Let's try to load GConf-2 library
*/
@@ -298,7 +298,7 @@
return proxy_array;
}
-static int initGProxyResolver() {
+static int initGProxyResolver(void) {
void *gio_handle;
gio_handle = dlopen("libgio-2.0.so", RTLD_LAZY);
--- a/src/java.base/unix/native/libnet/PlainSocketImpl.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libnet/PlainSocketImpl.c Sat Mar 03 08:21:47 2018 +0100
@@ -72,7 +72,7 @@
* which we shutdown but do not close the fd. The result is an fd that
* can be used for read/write.
*/
-static int getMarkerFD()
+static int getMarkerFD(void)
{
int sv[2];
--- a/src/java.base/unix/native/libnet/net_util_md.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.base/unix/native/libnet/net_util_md.c Sat Mar 03 08:21:47 2018 +0100
@@ -286,7 +286,7 @@
#else /* !DONT_ENABLE_IPV6 */
-jint IPv6_supported()
+jint IPv6_supported(void)
{
int fd;
void *ipv6_fn;
@@ -395,7 +395,7 @@
}
#endif /* DONT_ENABLE_IPV6 */
-jint reuseport_supported()
+jint reuseport_supported(void)
{
/* Do a simple dummy call, and try to figure out from that */
int one = 1;
@@ -718,13 +718,13 @@
/* Initialize stubs for blocking I/O workarounds (see src/solaris/native/java/net/linux_close.c) */
extern void aix_close_init();
-void platformInit () {
+void platformInit (void) {
aix_close_init();
}
#else
-void platformInit () {}
+void platformInit (void) {}
#endif
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLContext.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLContext.c Sat Mar 03 08:21:47 2018 +0100
@@ -113,7 +113,7 @@
* fully opaque alpha values.
*/
static void
-OGLContext_InitAlphaChannel()
+OGLContext_InitAlphaChannel(void)
{
GLboolean scissorEnabled;
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLFuncs.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLFuncs.c Sat Mar 03 08:21:47 2018 +0100
@@ -32,7 +32,7 @@
OGL_DECLARE_LIB_HANDLE();
jboolean
-OGLFuncs_OpenLibrary()
+OGLFuncs_OpenLibrary(void)
{
J2dRlsTraceLn(J2D_TRACE_INFO, "OGLFuncs_OpenLibrary");
@@ -47,7 +47,7 @@
}
void
-OGLFuncs_CloseLibrary()
+OGLFuncs_CloseLibrary(void)
{
J2dRlsTraceLn(J2D_TRACE_INFO, "OGLFuncs_CloseLibrary");
@@ -64,7 +64,7 @@
}
jboolean
-OGLFuncs_InitPlatformFuncs()
+OGLFuncs_InitPlatformFuncs(void)
{
J2dRlsTraceLn(J2D_TRACE_INFO, "OGLFuncs_InitPlatformFuncs");
@@ -83,7 +83,7 @@
}
jboolean
-OGLFuncs_InitBaseFuncs()
+OGLFuncs_InitBaseFuncs(void)
{
J2dRlsTraceLn(J2D_TRACE_INFO, "OGLFuncs_InitBaseFuncs");
@@ -102,7 +102,7 @@
}
jboolean
-OGLFuncs_InitExtFuncs()
+OGLFuncs_InitExtFuncs(void)
{
J2dRlsTraceLn(J2D_TRACE_INFO, "OGLFuncs_InitExtFuncs");
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLPaints.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLPaints.c Sat Mar 03 08:21:47 2018 +0100
@@ -153,7 +153,7 @@
static GLuint gradientTexID = 0;
static void
-OGLPaints_InitGradientTexture()
+OGLPaints_InitGradientTexture(void)
{
GLclampf priority = 1.0f;
@@ -500,7 +500,7 @@
"%s";
static void
-OGLPaints_InitMultiGradientTexture()
+OGLPaints_InitMultiGradientTexture(void)
{
GLclampf priority = 1.0f;
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLRenderQueue.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLRenderQueue.c Sat Mar 03 08:21:47 2018 +0100
@@ -717,7 +717,7 @@
* or SET_SCRATCH_SURFACE operation.
*/
OGLContext *
-OGLRenderQueue_GetCurrentContext()
+OGLRenderQueue_GetCurrentContext(void)
{
return oglc;
}
@@ -727,7 +727,7 @@
* SET_SURFACES operation.
*/
OGLSDOps *
-OGLRenderQueue_GetCurrentDestination()
+OGLRenderQueue_GetCurrentDestination(void)
{
return dstOps;
}
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLRenderer.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLRenderer.c Sat Mar 03 08:21:47 2018 +0100
@@ -785,7 +785,7 @@
}
void
-OGLRenderer_EnableAAParallelogramProgram()
+OGLRenderer_EnableAAParallelogramProgram(void)
{
J2dTraceLn(J2D_TRACE_INFO, "OGLRenderer_EnableAAParallelogramProgram");
@@ -802,7 +802,7 @@
}
void
-OGLRenderer_DisableAAParallelogramProgram()
+OGLRenderer_DisableAAParallelogramProgram(void)
{
J2dTraceLn(J2D_TRACE_INFO, "OGLRenderer_DisableAAParallelogramProgram");
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLTextRenderer.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLTextRenderer.c Sat Mar 03 08:21:47 2018 +0100
@@ -304,7 +304,7 @@
* returns 0.
*/
static GLhandleARB
-OGLTR_CreateLCDTextProgram()
+OGLTR_CreateLCDTextProgram(void)
{
GLhandleARB lcdTextProgram;
GLint loc;
@@ -508,7 +508,7 @@
* Disables any pending state associated with the current "glyph mode".
*/
static void
-OGLTR_DisableGlyphModeState()
+OGLTR_DisableGlyphModeState(void)
{
switch (glyphMode) {
case MODE_NO_CACHE_LCD:
--- a/src/java.desktop/share/native/common/java2d/opengl/OGLVertexCache.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/common/java2d/opengl/OGLVertexCache.c Sat Mar 03 08:21:47 2018 +0100
@@ -97,7 +97,7 @@
}
void
-OGLVertexCache_FlushVertexCache()
+OGLVertexCache_FlushVertexCache(void)
{
J2dTraceLn(J2D_TRACE_INFO, "OGLVertexCache_FlushVertexCache");
@@ -147,7 +147,7 @@
}
static jboolean
-OGLVertexCache_InitMaskCache()
+OGLVertexCache_InitMaskCache(void)
{
J2dTraceLn(J2D_TRACE_INFO, "OGLVertexCache_InitMaskCache");
--- a/src/java.desktop/share/native/libawt/awt/image/cvutils/img_colors.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libawt/awt/image/cvutils/img_colors.c Sat Mar 03 08:21:47 2018 +0100
@@ -90,7 +90,7 @@
#endif
static void
-init_matrices()
+init_matrices(void)
{
static int done = 0;
int i;
@@ -193,7 +193,7 @@
}
static void
-init_primaries() {
+init_primaries(void) {
int r, g, b;
for (r = 0; r < 256; r += (r?128:127)) {
@@ -207,7 +207,7 @@
}
static void
-init_pastels() {
+init_pastels(void) {
int i;
/* very light colors */
for (i = 6; i >= 0; --i)
@@ -217,14 +217,14 @@
}
static void
-init_grays() {
+init_grays(void) {
int i;
for (i = 15; i < 255; i += 16)
add_color(i, i, i, TRUE);
}
static void
-init_mac_palette() {
+init_mac_palette(void) {
add_color(255, 255, 204, TRUE);
add_color(255, 255, 0, TRUE);
add_color(255, 204, 153, TRUE);
--- a/src/java.desktop/share/native/libawt/awt/image/gif/gifdecoder.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libawt/awt/image/gif/gifdecoder.c Sat Mar 03 08:21:47 2018 +0100
@@ -85,13 +85,13 @@
/* Place holders for the old native interface. */
long
-sun_awt_image_GifImageDecoder_parseImage()
+sun_awt_image_GifImageDecoder_parseImage(void)
{
return 0;
}
void
-sun_awt_image_GifImageDecoder_initIDs()
+sun_awt_image_GifImageDecoder_initIDs(void)
{
}
--- a/src/java.desktop/share/native/libawt/java2d/Trace.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libawt/java2d/Trace.c Sat Mar 03 08:21:47 2018 +0100
@@ -73,7 +73,7 @@
}
JNIEXPORT void JNICALL
-J2dTraceInit()
+J2dTraceInit(void)
{
char *j2dTraceLevelString = getenv("J2D_TRACE_LEVEL");
char *j2dTraceFileName;
--- a/src/java.desktop/share/native/libawt/java2d/loops/AlphaMath.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libawt/java2d/loops/AlphaMath.c Sat Mar 03 08:21:47 2018 +0100
@@ -28,7 +28,7 @@
unsigned char mul8table[256][256];
unsigned char div8table[256][256];
-void initAlphaTables()
+void initAlphaTables(void)
{
unsigned int i;
unsigned int j;
--- a/src/java.desktop/share/native/libfontmanager/DrawGlyphList.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libfontmanager/DrawGlyphList.c Sat Mar 03 08:21:47 2018 +0100
@@ -861,7 +861,7 @@
* data, it needs only 512 bytes - plus a few more of overhead - and saves
* about that many intrinsic function calls plus other FP calculations.
*/
-void initLCDGammaTables() {
+void initLCDGammaTables(void) {
memset(lcdGammaLUT, 0, LCDLUTCOUNT * sizeof(UInt8*));
memset(lcdInvGammaLUT, 0, LCDLUTCOUNT * sizeof(UInt8*));
/* printDefaultTables(140); */
--- a/src/java.desktop/share/native/libfontmanager/sunFont.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libfontmanager/sunFont.c Sat Mar 03 08:21:47 2018 +0100
@@ -343,7 +343,7 @@
(*env)->ReleasePrimitiveArrayCritical(env, results, nresults, 0);
}
-JNIEXPORT TTLayoutTableCache* newLayoutTableCache() {
+JNIEXPORT TTLayoutTableCache* newLayoutTableCache(void) {
TTLayoutTableCache* ltc = calloc(1, sizeof(TTLayoutTableCache));
if (ltc) {
int i;
--- a/src/java.desktop/share/native/libjsound/Utilities.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libjsound/Utilities.c Sat Mar 03 08:21:47 2018 +0100
@@ -27,7 +27,7 @@
#include "Utilities.h"
-int UTIL_IsBigEndianPlatform() {
+int UTIL_IsBigEndianPlatform(void) {
#ifdef _LITTLE_ENDIAN
return 0;
#else
--- a/src/java.desktop/share/native/libsplashscreen/splashscreen_gfx_impl.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libsplashscreen/splashscreen_gfx_impl.c Sat Mar 03 08:21:47 2018 +0100
@@ -335,7 +335,7 @@
}
int
-platformByteOrder()
+platformByteOrder(void)
{
int test = 1;
--- a/src/java.desktop/share/native/libsplashscreen/splashscreen_impl.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/share/native/libsplashscreen/splashscreen_impl.c Sat Mar 03 08:21:47 2018 +0100
@@ -34,7 +34,7 @@
int splashIsVisible = 0;
Splash *
-SplashGetInstance()
+SplashGetInstance(void)
{
static Splash splash;
static int preInitialized = 0;
@@ -58,7 +58,7 @@
}
SPLASHEXPORT void
-SplashInit()
+SplashInit(void)
{
Splash *splash = SplashGetInstance();
@@ -71,7 +71,7 @@
}
SPLASHEXPORT void
-SplashClose()
+SplashClose(void)
{
Splash *splash = SplashGetInstance();
--- a/src/java.desktop/unix/native/common/awt/X11Color.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/common/awt/X11Color.c Sat Mar 03 08:21:47 2018 +0100
@@ -105,7 +105,7 @@
#define MACHMAPSIZE (sizeof(machinemap) / sizeof(machinemap[0]))
-int getVirtCubeSize() {
+int getVirtCubeSize(void) {
struct utsname name;
int i, ret;
--- a/src/java.desktop/unix/native/common/awt/fontpath.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/common/awt/fontpath.c Sat Mar 03 08:21:47 2018 +0100
@@ -322,7 +322,7 @@
#ifndef HEADLESS
-static char **getX11FontPath ()
+static char **getX11FontPath (void)
{
char **x11Path, **fontdirs;
int i, pos, slen, nPaths, numDirs;
@@ -581,7 +581,7 @@
#include <fontconfig/fontconfig.h>
-static void* openFontConfig() {
+static void* openFontConfig(void) {
char *homeEnv;
static char *homeEnvStr = "HOME="; /* must be static */
@@ -741,7 +741,7 @@
typedef FcChar8* (*FcStrListNextFuncType)(FcStrList *list);
typedef FcChar8* (*FcStrListDoneFuncType)(FcStrList *list);
-static char **getFontConfigLocations() {
+static char **getFontConfigLocations(void) {
char **fontdirs;
int numdirs = 0;
--- a/src/java.desktop/unix/native/common/java2d/opengl/GLXGraphicsConfig.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/common/java2d/opengl/GLXGraphicsConfig.c Sat Mar 03 08:21:47 2018 +0100
@@ -59,7 +59,7 @@
* GraphicsConfig in the environment.
*/
static jboolean
-GLXGC_InitGLX()
+GLXGC_InitGLX(void)
{
int errorbase, eventbase;
const char *version;
@@ -115,7 +115,7 @@
* calling this method.
*/
jboolean
-GLXGC_IsGLXAvailable()
+GLXGC_IsGLXAvailable(void)
{
static jboolean glxAvailable = JNI_FALSE;
static jboolean firstTime = JNI_TRUE;
--- a/src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt/awt/awt_LoadLibrary.c Sat Mar 03 08:21:47 2018 +0100
@@ -51,7 +51,7 @@
first loaded */
JavaVM *jvm;
-JNIEXPORT jboolean JNICALL AWTIsHeadless() {
+JNIEXPORT jboolean JNICALL AWTIsHeadless(void) {
static JNIEnv *env = NULL;
static jboolean isHeadless;
jmethodID headlessFn;
--- a/src/java.desktop/unix/native/libawt/awt/awt_Mlib.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt/awt/awt_Mlib.c Sat Mar 03 08:21:47 2018 +0100
@@ -137,11 +137,11 @@
return ret;
}
-mlib_start_timer awt_setMlibStartTimer() {
+mlib_start_timer awt_setMlibStartTimer(void) {
return start_timer;
}
-mlib_stop_timer awt_setMlibStopTimer() {
+mlib_stop_timer awt_setMlibStopTimer(void) {
return stop_timer;
}
--- a/src/java.desktop/unix/native/libawt_headless/awt/HeadlessToolkit.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_headless/awt/HeadlessToolkit.c Sat Mar 03 08:21:47 2018 +0100
@@ -39,7 +39,7 @@
#ifndef STATIC_BUILD
// The same function exists in libawt.a::awt_LoadLibrary.c
-JNIEXPORT jboolean JNICALL AWTIsHeadless() {
+JNIEXPORT jboolean JNICALL AWTIsHeadless(void) {
return JNI_TRUE;
}
#endif
--- a/src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/awt_GraphicsEnv.c Sat Mar 03 08:21:47 2018 +0100
@@ -636,7 +636,7 @@
}
#endif
#if !defined(__linux__) && !defined(MACOSX) /* Solaris */
-static void xinerama_init_solaris()
+static void xinerama_init_solaris(void)
{
void* libHandle = NULL;
unsigned char fbhints[MAXFRAMEBUFFERS];
@@ -920,10 +920,10 @@
}
return 0;
}
-jboolean isXShmAttachFailed() {
+jboolean isXShmAttachFailed(void) {
return xshmAttachFailed;
}
-void resetXShmAttachFailed() {
+void resetXShmAttachFailed(void) {
xshmAttachFailed = JNI_FALSE;
}
--- a/src/java.desktop/unix/native/libawt_xawt/awt/awt_InputMethod.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/awt_InputMethod.c Sat Mar 03 08:21:47 2018 +0100
@@ -190,7 +190,7 @@
* It is used in setting the time in Java-level InputEvents
*/
jlong
-awt_util_nowMillisUTC()
+awt_util_nowMillisUTC(void)
{
struct timeval t;
gettimeofday(&t, NULL);
--- a/src/java.desktop/unix/native/libawt_xawt/awt/awt_Robot.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/awt_Robot.c Sat Mar 03 08:21:47 2018 +0100
@@ -93,7 +93,7 @@
}
}
-static int32_t isXTestAvailable() {
+static int32_t isXTestAvailable(void) {
int32_t major_opcode, first_event, first_error;
int32_t event_basep, error_basep, majorp, minorp;
int32_t isXTestAvailable;
--- a/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/gtk2_interface.c Sat Mar 03 08:21:47 2018 +0100
@@ -459,7 +459,7 @@
/**
* Functions for sun_awt_X11_GtkFileDialogPeer.c
*/
-static void gtk2_file_chooser_load()
+static void gtk2_file_chooser_load(void)
{
fp_gtk_file_chooser_get_filename = dl_symbol(
"gtk_file_chooser_get_filename");
@@ -845,7 +845,7 @@
return NULL;
}
-int gtk2_unload()
+int gtk2_unload(void)
{
int i;
char *gtk2_error;
@@ -886,7 +886,7 @@
/* Dispatch all pending events from the GTK event loop.
* This is needed to catch theme change and update widgets' style.
*/
-static void flush_gtk_event_loop()
+static void flush_gtk_event_loop(void)
{
while( (*fp_g_main_context_iteration)(NULL, FALSE));
}
@@ -895,7 +895,7 @@
* Initialize components of containment hierarchy. This creates a GtkFixed
* inside a GtkWindow. All widgets get realized.
*/
-static void init_containers()
+static void init_containers(void)
{
if (gtk2_window == NULL)
{
@@ -1143,7 +1143,7 @@
return arrow;
}
-static GtkAdjustment* create_adjustment()
+static GtkAdjustment* create_adjustment(void)
{
return (GtkAdjustment *)
(*fp_gtk_adjustment_new)(50.0, 0.0, 100.0, 10.0, 20.0, 20.0);
--- a/src/java.desktop/unix/native/libawt_xawt/awt/gtk3_interface.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/gtk3_interface.c Sat Mar 03 08:21:47 2018 +0100
@@ -227,7 +227,7 @@
/**
* Functions for sun_awt_X11_GtkFileDialogPeer.c
*/
-static void gtk3_file_chooser_load()
+static void gtk3_file_chooser_load(void)
{
fp_gtk_file_chooser_get_filename = dl_symbol(
"gtk_file_chooser_get_filename");
@@ -254,7 +254,7 @@
fp_gdk_x11_drawable_get_xid = dl_symbol("gdk_x11_window_get_xid");
}
-static void empty() {}
+static void empty(void) {}
static gboolean gtk3_version_3_10 = TRUE;
static gboolean gtk3_version_3_14 = FALSE;
@@ -643,7 +643,7 @@
return NULL;
}
-static int gtk3_unload()
+static int gtk3_unload(void)
{
int i;
char *gtk3_error;
@@ -679,7 +679,7 @@
/* Dispatch all pending events from the GTK event loop.
* This is needed to catch theme change and update widgets' style.
*/
-static void flush_gtk_event_loop()
+static void flush_gtk_event_loop(void)
{
while((*fp_g_main_context_iteration)(NULL));
}
@@ -688,7 +688,7 @@
* Initialize components of containment hierarchy. This creates a GtkFixed
* inside a GtkWindow. All widgets get realized.
*/
-static void init_containers()
+static void init_containers(void)
{
if (gtk3_window == NULL)
{
@@ -897,7 +897,7 @@
return arrow;
}
-static GtkAdjustment* create_adjustment()
+static GtkAdjustment* create_adjustment(void)
{
return (GtkAdjustment *)
(*fp_gtk_adjustment_new)(50.0, 0.0, 100.0, 10.0, 20.0, 20.0);
--- a/src/java.desktop/unix/native/libawt_xawt/awt/gtk_interface.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/gtk_interface.c Sat Mar 03 08:21:47 2018 +0100
@@ -83,7 +83,7 @@
return load_order;
}
-static GtkLib* get_loaded() {
+static GtkLib* get_loaded(void) {
GtkLib** libs = get_libs_order(GTK_ANY);
while(!gtk && *libs) {
GtkLib* lib = *libs++;
--- a/src/java.desktop/unix/native/libawt_xawt/awt/list.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/list.c Sat Mar 03 08:21:47 2018 +0100
@@ -73,12 +73,7 @@
/** ------------------------------------------------------------------------
Sets the pointers of the specified list to NULL.
--------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
void zero_list(list_ptr lp)
-#else
-void zero_list(lp)
- list_ptr lp;
-#endif
{
lp->next = NULL;
lp->ptr.item = NULL;
@@ -92,13 +87,7 @@
and the next pointer in the new node is set to NULL.
Returns 1 if successful, 0 if the malloc failed.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
int32_t add_to_list(list_ptr lp, void *item)
-#else
-int32_t add_to_list(lp, item)
- list_ptr lp;
- void *item;
-#endif
{
while (lp->next) {
lp = lp->next;
@@ -118,7 +107,7 @@
Creates a new list and sets its pointers to NULL.
Returns a pointer to the new list.
-------------------------------------------------------------------- **/
-list_ptr new_list ()
+list_ptr new_list (void)
{
list_ptr lp;
@@ -140,13 +129,7 @@
curr pointer in the new list is the same as in the old list.
Returns a pointer to the new list head.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
list_ptr dup_list_head(list_ptr lp, int32_t start_at_curr)
-#else
-list_ptr dup_list_head(lp, start_at_curr)
- list_ptr lp;
- int32_t start_at_curr;
-#endif
{
list_ptr new_list;
@@ -164,12 +147,7 @@
/** ------------------------------------------------------------------------
Returns the number of items in the list.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
uint32_t list_length(list_ptr lp)
-#else
-uint32_t list_length(lp)
- list_ptr lp;
-#endif
{
uint32_t count = 0;
@@ -191,13 +169,7 @@
Returns a pointer to the item, so the caller can free it if it
so desires. If a match is not found, returns NULL.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
void *delete_from_list(list_ptr lp, void *item)
-#else
-void *delete_from_list(lp, item)
- list_ptr lp;
- void *item;
-#endif
{
list_ptr new_next;
@@ -222,13 +194,7 @@
with new_list(). If free_items is true, each item pointed to
from the node is freed, in addition to the node itself.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
void delete_list(list_ptr lp, int32_t free_items)
-#else
-void delete_list(lp, free_items)
- list_ptr lp;
- int32_t free_items;
-#endif
{
list_ptr del_node;
void *item;
@@ -244,13 +210,7 @@
}
}
-#if NeedFunctionPrototypes
void delete_list_destroying(list_ptr lp, void destructor(void *item))
-#else
-void delete_list_destroying(lp, destructor)
- list_ptr lp;
- void (*destructor)();
-#endif
{
list_ptr del_node;
void *item;
@@ -272,12 +232,7 @@
Sets the list head node's curr ptr to the first node in the list.
Returns NULL if the list is empty.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
void * first_in_list(list_ptr lp)
-#else
-void * first_in_list(lp)
- list_ptr lp;
-#endif
{
if (! lp) {
@@ -294,12 +249,7 @@
first_in_list must have been called prior.
Returns NULL if no next item.
-------------------------------------------------------------------- **/
-#if NeedFunctionPrototypes
void * next_in_list(list_ptr lp)
-#else
-void * next_in_list(lp)
- list_ptr lp;
-#endif
{
if (! lp) {
@@ -312,12 +262,7 @@
return lp->ptr.curr ? lp->ptr.curr->ptr.item : NULL;
}
-#if NeedFunctionPrototypes
int32_t list_is_empty(list_ptr lp)
-#else
-int32_t list_is_empty(lp)
- list_ptr lp;
-#endif
{
return (lp == NULL || lp->next == NULL);
}
--- a/src/java.desktop/unix/native/libawt_xawt/awt/multiVis.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/awt/multiVis.c Sat Mar 03 08:21:47 2018 +0100
@@ -152,68 +152,47 @@
/* Prototype Declarations for Static Functions */
static void TransferImage(
-#if NeedFunctionPrototypes
Display *, XImage *,int32_t, int32_t , image_region_type*,
XImage *,int32_t ,int32_t
-#endif
);
static XImage * ReadRegionsInList(
-#if NeedFunctionPrototypes
Display *, Visual *, int32_t ,int32_t ,int32_t ,
int32_t , XRectangle, list_ptr
-#endif
);
static list_ptr make_region_list(
-#if NeedFunctionPrototypes
Display*, Window, XRectangle*,
int32_t*, int32_t, XVisualInfo**, int32_t *
-#endif
);
static void destroy_region_list(
-#if NeedFunctionPrototypes
list_ptr
-#endif
) ;
static void subtr_rect_from_image_region(
-#if NeedFunctionPrototypes
image_region_type *, int32_t , int32_t , int32_t , int32_t
-#endif
);
static void add_rect_to_image_region(
-#if NeedFunctionPrototypes
image_region_type *,
int32_t , int32_t , int32_t , int32_t
-#endif
);
static int32_t src_in_region_list(
-#if NeedFunctionPrototypes
image_win_type *, list_ptr
-#endif
);
static void add_window_to_list(
-#if NeedFunctionPrototypes
list_ptr, Window, int32_t, int32_t ,
int32_t , int32_t , int32_t , int32_t, int32_t,
Visual*, Colormap, Window
-#endif
);
static int32_t src_in_image(
-#if NeedFunctionPrototypes
image_win_type *, int32_t , XVisualInfo**
-#endif
);
static int32_t src_in_overlay(
-#if NeedFunctionPrototypes
image_region_type *, int32_t, OverlayInfo *, int32_t*, int32_t*
-#endif
);
/* End of Prototype Declarations */
-void initFakeVisual(Vis)
-Visual *Vis ;
+void initFakeVisual(Visual *Vis)
{
Vis->ext_data=NULL;
Vis->class = DirectColor ;
@@ -228,26 +207,32 @@
* awt_DataTransferer.c as well.
*/
+
+/*
+ * srcRootWinid: root win on which grab was done
+ * x, y: root rel UL corner of bounding box of grab
+ * width, height: size of bounding box of grab
+ * vis_regions: list of regions to read from
+ */
int32_t
-GetMultiVisualRegions(disp,srcRootWinid, x, y, width, height,
- transparentOverlays,numVisuals, pVisuals,numOverlayVisuals, pOverlayVisuals,
- numImageVisuals, pImageVisuals,vis_regions,vis_image_regions,allImage)
- Display *disp;
- Window srcRootWinid; /* root win on which grab was done */
- int32_t x; /* root rel UL corner of bounding box of grab */
- int32_t y;
- uint32_t width; /* size of bounding box of grab */
- uint32_t height;
- int32_t *transparentOverlays ;
- int32_t *numVisuals;
- XVisualInfo **pVisuals;
- int32_t *numOverlayVisuals;
- OverlayInfo **pOverlayVisuals;
- int32_t *numImageVisuals;
- XVisualInfo ***pImageVisuals;
- list_ptr *vis_regions; /* list of regions to read from */
- list_ptr *vis_image_regions ;
- int32_t *allImage ;
+GetMultiVisualRegions(
+ Display *disp,
+ Window srcRootWinid,
+ int32_t x,
+ int32_t y,
+ uint32_t width,
+ uint32_t height,
+ int32_t *transparentOverlays,
+ int32_t *numVisuals,
+ XVisualInfo **pVisuals,
+ int32_t *numOverlayVisuals,
+ OverlayInfo **pOverlayVisuals,
+ int32_t *numImageVisuals,
+ XVisualInfo ***pImageVisuals,
+ list_ptr *vis_regions,
+ list_ptr *vis_image_regions,
+ int32_t *allImage
+)
{
int32_t hasNonDefault;
XRectangle bbox; /* bounding box of grabbed area */
@@ -290,12 +275,11 @@
}
-static void TransferImage(disp,reg_image,srcw,srch,reg,
- target_image,dst_x,dst_y)
-Display *disp;
-XImage *reg_image,*target_image ;
-image_region_type *reg;
-int32_t srcw,srch,dst_x , dst_y ;
+static void TransferImage(
+ Display *disp, XImage *reg_image,
+ int32_t srcw, int32_t srch,
+ image_region_type *reg, XImage *target_image,
+ int32_t dst_x, int32_t dst_y)
{
int32_t ncolors;
int32_t i,j,old_pixel,new_pixel,red_ind,green_ind,blue_ind ;
@@ -385,14 +369,20 @@
free(colors);
}
+/*
+ * bbox: bounding box of grabbed area
+ * regions: list of regions to read from
+ */
static XImage *
-ReadRegionsInList(disp,fakeVis,depth,format,width,height,bbox,regions)
-Display *disp ;
-Visual *fakeVis ;
-int32_t depth , width , height ;
-int32_t format ;
-XRectangle bbox; /* bounding box of grabbed area */
-list_ptr regions;/* list of regions to read from */
+ReadRegionsInList(
+ Display *disp,
+ Visual *fakeVis,
+ int32_t depth,
+ int32_t format,
+ int32_t width, int32_t height,
+ XRectangle bbox,
+ list_ptr regions
+)
{
XImage *ximage ;
image_region_type* reg;
@@ -446,26 +436,31 @@
/** ------------------------------------------------------------------------
------------------------------------------------------------------------ **/
-XImage *ReadAreaToImage(disp, srcRootWinid, x, y, width, height,
- numVisuals,pVisuals,numOverlayVisuals,pOverlayVisuals,numImageVisuals,
- pImageVisuals,vis_regions,vis_image_regions,format,allImage)
- Display *disp;
- Window srcRootWinid; /* root win on which grab was done */
- int32_t x; /* root rel UL corner of bounding box of grab */
- int32_t y;
- uint32_t width; /* size of bounding box of grab */
- uint32_t height;
- /** int32_t transparentOverlays; ***/
- int32_t numVisuals;
- XVisualInfo *pVisuals;
- int32_t numOverlayVisuals;
- OverlayInfo *pOverlayVisuals;
- int32_t numImageVisuals;
- XVisualInfo **pImageVisuals;
- list_ptr vis_regions; /* list of regions to read from */
- list_ptr vis_image_regions ;/* list of regions to read from */
- int32_t format;
- int32_t allImage ;
+/*
+ * srcRootWinid: root win on which grab was done
+ * x, y: root rel UL corner of bounding box of grab
+ * width, height: size of bounding box of grab
+ * vis_regions: list of regions to read from
+ * vis_image_regions: list of regions to read from
+ */
+XImage *ReadAreaToImage(
+ Display *disp,
+ Window srcRootWinid,
+ int32_t x,
+ int32_t y,
+ uint32_t width,
+ uint32_t height,
+ int32_t numVisuals,
+ XVisualInfo *pVisuals,
+ int32_t numOverlayVisuals,
+ OverlayInfo *pOverlayVisuals,
+ int32_t numImageVisuals,
+ XVisualInfo **pImageVisuals,
+ list_ptr vis_regions,
+ list_ptr vis_image_regions ,
+ int32_t format,
+ int32_t allImage
+)
{
image_region_type *reg;
XRectangle bbox; /* bounding box of grabbed area */
@@ -639,18 +634,21 @@
windows with the same visual into a region.
image_wins must point to an existing list struct that's already
been zeroed (zero_list()).
+
+ bbox: bnding box of area we want
+ x_rootrel, y_rootrel: pos of curr WRT root
+ pclip: visible part of curr, not obscurred by ancestors
------------------------------------------------------------------------ **/
-static void make_src_list( disp, image_wins, bbox, curr, x_rootrel, y_rootrel,
- curr_attrs, pclip)
- Display *disp;
- list_ptr image_wins;
- XRectangle *bbox; /* bnding box of area we want */
- Window curr;
- int32_t x_rootrel; /* pos of curr WRT root */
- int32_t y_rootrel;
- XWindowAttributes *curr_attrs;
- XRectangle *pclip; /* visible part of curr, not */
- /* obscurred by ancestors */
+static void make_src_list(
+ Display *disp,
+ list_ptr image_wins,
+ XRectangle *bbox,
+ Window curr,
+ int32_t x_rootrel,
+ int32_t y_rootrel,
+ XWindowAttributes *curr_attrs,
+ XRectangle *pclip
+)
{
XWindowAttributes child_attrs;
Window root, parent, *child; /* variables for XQueryTree() */
@@ -737,15 +735,15 @@
there will be two regions in the list.
Returns a pointer to the list.
------------------------------------------------------------------------ **/
-static list_ptr make_region_list( disp, win, bbox, hasNonDefault,
- numImageVisuals, pImageVisuals, allImage)
- Display *disp;
- Window win;
- XRectangle *bbox;
- int32_t *hasNonDefault;
- int32_t numImageVisuals;
- XVisualInfo **pImageVisuals;
- int32_t *allImage;
+static list_ptr make_region_list(
+ Display *disp,
+ Window win,
+ XRectangle *bbox,
+ int32_t *hasNonDefault,
+ int32_t numImageVisuals,
+ XVisualInfo **pImageVisuals,
+ int32_t *allImage
+)
{
XWindowAttributes win_attrs;
list image_wins;
@@ -840,8 +838,7 @@
/** ------------------------------------------------------------------------
Destructor called from destroy_region_list().
------------------------------------------------------------------------ **/
-void destroy_image_region( image_region)
- image_region_type *image_region;
+void destroy_image_region(image_region_type *image_region)
{
XDestroyRegion( image_region->visible_region);
free( (void *) image_region);
@@ -850,8 +847,7 @@
/** ------------------------------------------------------------------------
Destroys the region list, destroying all the regions contained in it.
------------------------------------------------------------------------ **/
-static void destroy_region_list( rlist)
- list_ptr rlist;
+static void destroy_region_list(list_ptr rlist)
{
delete_list_destroying( rlist, (DESTRUCT_FUNC_PTR)destroy_image_region);
}
@@ -863,12 +859,13 @@
only provides a way to subtract one region from another, not a
rectangle from a region.
------------------------------------------------------------------------ **/
-static void subtr_rect_from_image_region( image_region, x, y, width, height)
- image_region_type *image_region;
- int32_t x;
- int32_t y;
- int32_t width;
- int32_t height;
+static void subtr_rect_from_image_region(
+ image_region_type *image_region,
+ int32_t x,
+ int32_t y,
+ int32_t width,
+ int32_t height
+)
{
XRectangle rect;
Region rect_region;
@@ -888,12 +885,13 @@
/** ------------------------------------------------------------------------
Adds the specified rectangle to the region in image_region.
------------------------------------------------------------------------ **/
-static void add_rect_to_image_region( image_region, x, y, width, height)
- image_region_type *image_region;
- int32_t x;
- int32_t y;
- int32_t width;
- int32_t height;
+static void add_rect_to_image_region(
+ image_region_type *image_region,
+ int32_t x,
+ int32_t y,
+ int32_t width,
+ int32_t height
+)
{
XRectangle rect;
@@ -910,9 +908,7 @@
Returns TRUE if the given src's visual is already represented in
the image_regions list, FALSE otherwise.
------------------------------------------------------------------------ **/
-static int32_t src_in_region_list( src, image_regions)
- image_win_type *src;
- list_ptr image_regions;
+static int32_t src_in_region_list(image_win_type *src, list_ptr image_regions)
{
image_region_type *ir;
@@ -931,20 +927,20 @@
/** ------------------------------------------------------------------------
Makes a new entry in image_wins with the given fields filled in.
------------------------------------------------------------------------ **/
-static void add_window_to_list( image_wins, w, xrr, yrr, x_vis, y_vis,
- width, height, border_width,vis, cmap, parent)
- list_ptr image_wins;
- Window w;
- int32_t xrr;
- int32_t yrr;
- int32_t x_vis;
- int32_t y_vis;
- int32_t width;
- int32_t height;
- int32_t border_width;
- Visual *vis;
- Colormap cmap;
- Window parent;
+static void add_window_to_list(
+ list_ptr image_wins,
+ Window w,
+ int32_t xrr,
+ int32_t yrr,
+ int32_t x_vis,
+ int32_t y_vis,
+ int32_t width,
+ int32_t height,
+ int32_t border_width,
+ Visual *vis,
+ Colormap cmap,
+ Window parent
+)
{
image_win_type *new_src;
@@ -970,10 +966,11 @@
Returns TRUE if the given src's visual is in the image planes,
FALSE otherwise.
------------------------------------------------------------------------ **/
-static int32_t src_in_image( src, numImageVisuals, pImageVisuals)
- image_win_type *src;
- int32_t numImageVisuals;
- XVisualInfo **pImageVisuals;
+static int32_t src_in_image(
+ image_win_type *src,
+ int32_t numImageVisuals,
+ XVisualInfo **pImageVisuals
+)
{
int32_t i;
@@ -990,13 +987,13 @@
Returns TRUE if the given src's visual is in the overlay planes
and transparency is possible, FALSE otherwise.
------------------------------------------------------------------------ **/
-static int32_t src_in_overlay( src, numOverlayVisuals, pOverlayVisuals,
- transparentColor, transparentType)
- image_region_type *src;
- int32_t numOverlayVisuals;
- OverlayInfo *pOverlayVisuals;
- int32_t *transparentColor;
- int32_t *transparentType;
+static int32_t src_in_overlay(
+ image_region_type *src,
+ int32_t numOverlayVisuals,
+ OverlayInfo *pOverlayVisuals,
+ int32_t *transparentColor,
+ int32_t *transparentType
+)
{
int32_t i;
@@ -1062,31 +1059,31 @@
* If the routine sucessfully obtained the visual information, it returns zero.
* If the routine didn't obtain the visual information, it returns non-zero.
*
+ * display: Which X server (aka "display").
+ * screen: Which screen of the "display".
+ * transparentOverlays: Non-zero if there's at least one overlay visual and if
+ * at least one of those supports a transparent pixel.
+ * numVisuals: Number of XVisualInfo struct's pointed to by pVisuals.
+ * pVisuals: All of the device's visuals.
+ * numOverlayVisuals: Number of OverlayInfo's pointed to by pOverlayVisuals.
+ * If this number is zero, the device does not have overlay planes.
+ * pOverlayVisuals: The device's overlay plane visual information.
+ * numImageVisuals: Number of XVisualInfo's pointed to by pImageVisuals.
+ * pImageVisuals: The device's image visuals.
+ *
******************************************************************************/
-int32_t GetXVisualInfo(display, screen, transparentOverlays,
- numVisuals, pVisuals,
- numOverlayVisuals, pOverlayVisuals,
- numImageVisuals, pImageVisuals)
-
- Display *display; /* Which X server (aka "display"). */
- int32_t screen; /* Which screen of the "display". */
- int32_t *transparentOverlays; /* Non-zero if there's at least one
- * overlay visual and if at least one
- * of those supports a transparent
- * pixel. */
- int32_t *numVisuals; /* Number of XVisualInfo struct's
- * pointed to by pVisuals. */
- XVisualInfo **pVisuals; /* All of the device's visuals. */
- int32_t *numOverlayVisuals; /* Number of OverlayInfo's pointed
- * to by pOverlayVisuals. If this
- * number is zero, the device does
- * not have overlay planes. */
- OverlayInfo **pOverlayVisuals; /* The device's overlay plane visual
- * information. */
- int32_t *numImageVisuals; /* Number of XVisualInfo's pointed
- * to by pImageVisuals. */
- XVisualInfo ***pImageVisuals; /* The device's image visuals. */
+int32_t GetXVisualInfo(
+ Display *display,
+ int32_t screen,
+ int32_t *transparentOverlays,
+ int32_t *numVisuals,
+ XVisualInfo **pVisuals,
+ int32_t *numOverlayVisuals,
+ OverlayInfo **pOverlayVisuals,
+ int32_t *numImageVisuals,
+ XVisualInfo ***pImageVisuals
+)
{
XVisualInfo getVisInfo; /* Parameters of XGetVisualInfo */
int32_t mask;
@@ -1199,11 +1196,11 @@
*
******************************************************************************/
-void FreeXVisualInfo(pVisuals, pOverlayVisuals, pImageVisuals)
-
- XVisualInfo *pVisuals;
- OverlayInfo *pOverlayVisuals;
- XVisualInfo **pImageVisuals;
+void FreeXVisualInfo(
+ XVisualInfo *pVisuals,
+ OverlayInfo *pOverlayVisuals,
+ XVisualInfo **pImageVisuals
+)
{
XFree(pVisuals);
if (weCreateServerOverlayVisualsProperty)
--- a/src/java.desktop/unix/native/libawt_xawt/xawt/XToolkit.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/xawt/XToolkit.c Sat Mar 03 08:21:47 2018 +0100
@@ -316,7 +316,7 @@
{
}
-JNIEXPORT jboolean JNICALL AWTIsHeadless() {
+JNIEXPORT jboolean JNICALL AWTIsHeadless(void) {
#ifdef HEADLESS
return JNI_TRUE;
#else
@@ -407,7 +407,7 @@
// to 0).
static int32_t static_poll_timeout = 0;
-static Bool isMainThread() {
+static Bool isMainThread(void) {
return awt_MainThread == pthread_self();
}
@@ -417,7 +417,7 @@
* select() by writing to this pipe.
*/
static void
-awt_pipe_init() {
+awt_pipe_init(void) {
if (awt_pipe_inited) {
return;
@@ -450,7 +450,7 @@
/**
* Reads environment variables to initialize timeout fields.
*/
-static void readEnv() {
+static void readEnv(void) {
char * value;
int tmp_poll_alg;
static Boolean env_read = False;
@@ -717,7 +717,7 @@
* Schedules next auto-flush event or performs forced flush depending
* on the time of the previous flush.
*/
-void awt_output_flush() {
+void awt_output_flush(void) {
if (awt_next_flush_time == 0) {
JNIEnv *env = (JNIEnv *)JNU_GetEnv(jvm, JNI_VERSION_1_2);
@@ -744,7 +744,7 @@
/**
* Wakes-up poll() in performPoll
*/
-static void wakeUp() {
+static void wakeUp(void) {
static char wakeUp_char = 'p';
if (!isMainThread() && awt_pipe_inited) {
write ( AWT_WRITEPIPE, &wakeUp_char, 1 );
@@ -991,7 +991,7 @@
return num_buttons;
}
-int32_t getNumButtons() {
+int32_t getNumButtons(void) {
int32_t major_opcode, first_event, first_error;
int32_t xinputAvailable;
int32_t numDevices, devIdx, clsIdx;
--- a/src/java.desktop/unix/native/libawt_xawt/xawt/XWindow.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/xawt/XWindow.c Sat Mar 03 08:21:47 2018 +0100
@@ -452,7 +452,7 @@
};
static Boolean
-keyboardHasKanaLockKey()
+keyboardHasKanaLockKey(void)
{
static Boolean haveResult = FALSE;
static Boolean result = FALSE;
--- a/src/java.desktop/unix/native/libawt_xawt/xawt/awt_Taskbar.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/xawt/awt_Taskbar.c Sat Mar 03 08:21:47 2018 +0100
@@ -60,7 +60,7 @@
return result;
}
-static gboolean unity_load() {
+static gboolean unity_load(void) {
unity_libhandle = dlopen(UNITY_LIB_VERSIONED, RTLD_LAZY | RTLD_LOCAL);
if (unity_libhandle == NULL) {
unity_libhandle = dlopen(UNITY_LIB, RTLD_LAZY | RTLD_LOCAL);
--- a/src/java.desktop/unix/native/libawt_xawt/xawt/gnome_interface.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libawt_xawt/xawt/gnome_interface.c Sat Mar 03 08:21:47 2018 +0100
@@ -27,7 +27,7 @@
GNOME_URL_SHOW_TYPE *gnome_url_show = NULL;
-gboolean gnome_load() {
+gboolean gnome_load(void) {
void *vfs_handle;
void *gnome_handle;
const char *errmsg;
--- a/src/java.desktop/unix/native/libjsound/PLATFORM_API_SolarisOS_PCM.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libjsound/PLATFORM_API_SolarisOS_PCM.c Sat Mar 03 08:21:47 2018 +0100
@@ -37,7 +37,7 @@
///// implemented functions of DirectAudio.h
-INT32 DAUDIO_GetDirectAudioDeviceCount() {
+INT32 DAUDIO_GetDirectAudioDeviceCount(void) {
return (INT32) getAudioDeviceCount();
}
--- a/src/java.desktop/unix/native/libjsound/PLATFORM_API_SolarisOS_Ports.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libjsound/PLATFORM_API_SolarisOS_Ports.c Sat Mar 03 08:21:47 2018 +0100
@@ -138,7 +138,7 @@
///// implemented functions of Ports.h
-INT32 PORT_GetPortMixerCount() {
+INT32 PORT_GetPortMixerCount(void) {
return (INT32) getAudioDeviceCount();
}
--- a/src/java.desktop/unix/native/libjsound/PLATFORM_API_SolarisOS_Utils.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.desktop/unix/native/libjsound/PLATFORM_API_SolarisOS_Utils.c Sat Mar 03 08:21:47 2018 +0100
@@ -38,14 +38,14 @@
#define AD_CACHE_TIME 30
// return seconds
-long getTimeInSeconds() {
+long getTimeInSeconds(void) {
struct timeval tv;
gettimeofday(&tv, NULL);
return tv.tv_sec;
}
-int getAudioDeviceCount() {
+int getAudioDeviceCount(void) {
int count = MAX_AUDIO_DEVICES;
getAudioDevices(globalADPaths, &count);
--- a/src/java.instrument/share/native/libinstrument/PathCharsValidator.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.instrument/share/native/libinstrument/PathCharsValidator.c Sat Mar 03 08:21:47 2018 +0100
@@ -112,7 +112,7 @@
return 0;
}
-static void initialize() {
+static void initialize(void) {
// digit = "0" | "1" | "2" | "3" | "4" | "5" | "6" | "7" |
// "8" | "9"
jlong L_DIGIT = lowMaskRange('0', '9');
--- a/src/java.instrument/unix/native/libinstrument/FileSystemSupport_md.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/java.instrument/unix/native/libinstrument/FileSystemSupport_md.c Sat Mar 03 08:21:47 2018 +0100
@@ -34,7 +34,7 @@
#define slash '/'
-char pathSeparator() {
+char pathSeparator(void) {
return ':';
}
--- a/src/jdk.crypto.ucrypto/solaris/native/libj2ucrypto/nativeFunc.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.crypto.ucrypto/solaris/native/libj2ucrypto/nativeFunc.c Sat Mar 03 08:21:47 2018 +0100
@@ -72,7 +72,7 @@
/**
* Initialize native T4 crypto function pointers
*/
-jboolean* loadNative() {
+jboolean* loadNative(void) {
jboolean* buf;
void *lib;
--- a/src/jdk.jdwp.agent/share/native/libdt_socket/socketTransport.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.jdwp.agent/share/native/libdt_socket/socketTransport.c Sat Mar 03 08:21:47 2018 +0100
@@ -130,7 +130,7 @@
* Return the last error for this thread (may be NULL)
*/
static char*
-getLastError() {
+getLastError(void) {
return (char *)dbgsysTlsGet(tlsIndex);
}
@@ -223,7 +223,7 @@
}
static uint32_t
-getLocalHostAddress() {
+getLocalHostAddress(void) {
// Simple routine to guess localhost address.
// it looks up "localhost" and returns 127.0.0.1 if lookup
// fails.
--- a/src/jdk.jdwp.agent/share/native/libjdwp/eventFilter.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.jdwp.agent/share/native/libjdwp/eventFilter.c Sat Mar 03 08:21:47 2018 +0100
@@ -276,7 +276,7 @@
}
}
-static jboolean isVersionGte12x() {
+static jboolean isVersionGte12x(void) {
jint version;
jvmtiError err =
JVMTI_FUNC_PTR(gdata->jvmti,GetVersionNumber)(gdata->jvmti, &version);
--- a/src/jdk.jdwp.agent/share/native/libjdwp/eventHelper.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.jdwp.agent/share/native/libjdwp/eventHelper.c Sat Mar 03 08:21:47 2018 +0100
@@ -772,7 +772,7 @@
debugMonitorExit(commandQueueLock);
}
-void commandLoop_exitVmDeathLockOnError()
+void commandLoop_exitVmDeathLockOnError(void)
{
const char* MSG_BASE = "exitVmDeathLockOnError: error in JVMTI %s: %d\n";
jthread cur_thread = NULL;
--- a/src/jdk.jdwp.agent/share/native/libjdwp/log_messages.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.jdwp.agent/share/native/libjdwp/log_messages.c Sat Mar 03 08:21:47 2018 +0100
@@ -238,7 +238,7 @@
/* Finish up logging, flush output to the logfile. */
void
-finish_logging()
+finish_logging(void)
{
#ifdef JDWP_LOGGING
MUTEX_LOCK(my_mutex);
--- a/src/jdk.jdwp.agent/unix/native/libdt_socket/socket_md.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.jdwp.agent/unix/native/libdt_socket/socket_md.c Sat Mar 03 08:21:47 2018 +0100
@@ -273,7 +273,7 @@
#ifdef __solaris__
int
-dbgsysTlsAlloc() {
+dbgsysTlsAlloc(void) {
thread_key_t tk;
if (thr_keycreate(&tk, NULL)) {
perror("thr_keycreate");
@@ -328,7 +328,7 @@
#endif
long
-dbgsysCurrentTimeMillis() {
+dbgsysCurrentTimeMillis(void) {
struct timeval t;
gettimeofday(&t, 0);
return ((jlong)t.tv_sec) * 1000 + (jlong)(t.tv_usec/1000);
--- a/src/jdk.management/solaris/native/libmanagement_ext/UnixOperatingSystem.c Fri Mar 02 19:10:12 2018 +0100
+++ b/src/jdk.management/solaris/native/libmanagement_ext/UnixOperatingSystem.c Sat Mar 03 08:21:47 2018 +0100
@@ -51,7 +51,7 @@
static unsigned int num_cpus;
static kstat_ctl_t *kstat_ctrl = NULL;
-static void map_cpu_kstat_counters() {
+static void map_cpu_kstat_counters(void) {
kstat_t *kstat;
int i;
@@ -86,7 +86,7 @@
}
}
-static int init_cpu_kstat_counters() {
+static int init_cpu_kstat_counters(void) {
static int initialized = 0;
// Concurrence in this method is prevented by the lock in
@@ -100,7 +100,7 @@
return initialized ? 0 : -1;
}
-static void update_cpu_kstat_counters() {
+static void update_cpu_kstat_counters(void) {
if(kstat_chain_update(kstat_ctrl) != 0) {
free(cpu_loads);
map_cpu_kstat_counters();