8264502: (fc) FileDispatcherImpl.setDirect0 might return uninitialized variable on some platforms

Reviewed-by: alanb, bpb, michaelm
This commit is contained in:
Christoph Göttschkes 2021-04-02 09:19:53 +00:00 committed by Alan Bateman
parent da643cdb20
commit 4793557fa8

@ -1,5 +1,5 @@
/*
* Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2000, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -375,7 +375,7 @@ Java_sun_nio_ch_FileDispatcherImpl_setDirect0(JNIEnv *env, jclass clazz,
result = (int)file_stat.f_frsize;
}
#else
result == -1;
result = -1;
#endif
return result;
}