RFR: JDK-8354316 : clang/linux build fails with -Wunused-result warning at XToolkit.c:695:9 [v2]
Harshitha Onkar
honkar at openjdk.org
Wed May 14 21:28:37 UTC 2025
On Wed, 14 May 2025 04:23:18 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:
>> 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) < 0) {
>>> 696: // if block is left empty to avoid adding unused-result to
>>
>> Does it make sense to add a trace with `DTRACE_PRINTLN*`?
>>
>> It could be useful for debugging…
>
> yes If write does not return 1 might indicate an error, it would be good to log it. so we can skip this long comment
Updated
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/25217#discussion_r2089778602
More information about the build-dev
mailing list