Skip to content

Commit 563a335

Browse files
8342682: Errors related to unused code on Windows after 8339120 in dt_shmem jdwp security and jpackage
Reviewed-by: cjplummer, asemenyuk, almatvee
1 parent ec7c6be commit 563a335

File tree

4 files changed

+5
-6
lines changed

4 files changed

+5
-6
lines changed

src/jdk.crypto.mscapi/windows/native/libsunmscapi/security.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1313,6 +1313,7 @@ void showProperty(NCRYPT_HANDLE hKey) {
13131313
EXPORT_BLOB(NCRYPT_PKCS7_ENVELOPE_BLOB);
13141314
//EXPORT_BLOB(NCRYPTBUFFER_CERT_BLOB);
13151315
//EXPORT_BLOB(NCRYPT_PKCS8_PRIVATE_KEY_BLOB);
1316+
/*
13161317
BCryptBuffer bb;
13171318
bb.BufferType = NCRYPTBUFFER_PKCS_SECRET;
13181319
bb.cbBuffer = 18;
@@ -1321,6 +1322,7 @@ void showProperty(NCRYPT_HANDLE hKey) {
13211322
bbd.ulVersion = 0;
13221323
bbd.cBuffers = 1;
13231324
bbd.pBuffers = &bb;
1325+
*/
13241326
if(::NCryptExportKey(hKey, NULL, NCRYPT_PKCS8_PRIVATE_KEY_BLOB, NULL,
13251327
(PBYTE)buffer, 8192, &len, NCRYPT_SILENT_FLAG) == ERROR_SUCCESS) {
13261328
snprintf(header, sizeof(header), "NCRYPT_PKCS8_PRIVATE_KEY_BLOB %ls", NCRYPT_PKCS8_PRIVATE_KEY_BLOB);

src/jdk.jdi/windows/native/libdt_shmem/shmem_md.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,6 @@
3737
* yet.
3838
*/
3939

40-
static HANDLE memHandle = NULL;
41-
4240
int
4341
sysSharedMemCreate(const char *name, int length,
4442
sys_shmem_t *mem, void **buffer)

src/jdk.jdwp.agent/windows/native/libjdwp/proc_md.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@
3131

3232
#define MUTEX_T int
3333
#define MUTEX_INIT 0
34-
#define MUTEX_LOCK(x) /* FIXUP? */
35-
#define MUTEX_UNLOCK(x) /* FIXUP? */
34+
#define MUTEX_LOCK(x) ((void) (x)) /* FIXUP? */
35+
#define MUTEX_UNLOCK(x) ((void) (x)) /* FIXUP? */
3636
#define GET_THREAD_ID() GetCurrentThreadId()
3737
#define THREAD_T unsigned long
3838
#define PID_T int

src/jdk.jpackage/windows/native/libjpackage/VersionInfo.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2020, 2024, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -180,7 +180,6 @@ void VersionInfo::fillBuffer(std::ostream& buf) const {
180180
write(buf, createFIXEDFILEINFO()); // Value
181181
add32bitPadding(buf); // Padding2
182182

183-
const DWORD neutralLangId = (0x04b0 | MAKELANGID(LANG_NEUTRAL, SUBLANG_NEUTRAL) << 16);
184183
const DWORD engLangId = (0x04b0 | MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US) << 16);
185184

186185
do {

0 commit comments

Comments
 (0)