On Tue, 17 Dec 2024 14:57:42 GMT, Jan Kratochvil <jkratoch...@openjdk.org> wrote:
> clang-18.1.8-1.fc40.x86_64 > Fedora 40 x86_64 > fbd76ca8edd756ff2ebbc9f6477cc1a827df67b0 > > > src/java.desktop/unix/native/libawt_xawt/xawt/XToolkit.c:695:9: error: > ignoring return value of function declared with 'warn_unused_result' > attribute [-Werror,-Wunused-result] > 695 | write ( AWT_WRITEPIPE, &wakeUp_char, 1 ); > | ^~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > src/java.desktop/unix/native/libsplashscreen/splashscreen_sys.c:375:9: error: > ignoring return value of function declared with 'warn_unused_result' > attribute [-Werror,-Wunused-result] > 375 | write(splash->controlpipe[1], &code, 1); > | ^~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > src/java.desktop/unix/native/libsplashscreen/splashscreen_sys.c:713:5: error: > ignoring return value of function declared with 'warn_unused_result' > attribute [-Werror,-Wunused-result] > 713 | pipe(splash->controlpipe); > | ^~~~ ~~~~~~~~~~~~~~~~~~~ > src/jdk.crypto.cryptoki/share/native/libj2pkcs11/j2secmod.h:45:9: error: > 'dprintf' macro redefined [-Werror,-Wmacro-redefined] > 45 | #define dprintf(s) > | ^ > /usr/include/bits/stdio2.h:121:12: note: previous definition is here > 121 | # define dprintf(fd, ...) \ > | ^ > src/java.smartcardio/share/native/libj2pcsc/pcsc.c:48:9: error: 'dprintf' > macro redefined [-Werror,-Wmacro-redefined] > 48 | #define dprintf(s) > | ^ > /usr/include/bits/stdio2.h:121:12: note: previous definition is here > 121 | # define dprintf(fd, ...) \ > | ^ src/java.desktop/unix/native/libawt_xawt/xawt/XToolkit.c line 696: > 694: if (!isMainThread() && awt_pipe_inited) { > 695: if (write ( AWT_WRITEPIPE, &wakeUp_char, 1 ) != 1) { > 696: fprintf(stderr, "Cannot not write to AWT utility control: > %s\n", strerror(errno)); what happens to the process if this call fails ? Can it continue ? You can check by commenting out the call and see what happens when you run AWT tests And assuming it is a continuable error, can you do the print only in a DEBUG build ? src/java.desktop/unix/native/libsplashscreen/splashscreen_sys.c line 377: > 375: if (write(splash->controlpipe[1], &code, 1) != 1) { > 376: fprintf(stderr, "Cannot not write to splash screen control: > %s\n", strerror(errno)); > 377: } what happens to the process if this call fails ? Can it continue ? You can check by commenting out the call and see what happens when you run an app on Linux that uses splashScreen ? SwingSet2 would be sufficient. And assuming it is a continuable error, can you do the print only in a DEBUG build ? src/java.desktop/unix/native/libsplashscreen/splashscreen_sys.c line 716: > 714: SplashLock(splash); > 715: if (pipe(splash->controlpipe)) { > 716: fprintf(stderr, "Error creating pipe for splash screen control: > %s\n", strerror(errno)); what happens to the process if this call fails ? Can it continue ? You can check by commenting out the call and see what happens when you run an app on Linux that uses splashScreen ? SwingSet2 would be sufficient. And assuming it is a continuable error, can you do the print only in a DEBUG build ? ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/22794#discussion_r1894285156 PR Review Comment: https://git.openjdk.org/jdk/pull/22794#discussion_r1894285800 PR Review Comment: https://git.openjdk.org/jdk/pull/22794#discussion_r1894285886