openjdk/jdk · error
no '\' found in the full path of the executable
Error message
no '\' found in the full path of the executable
What it means
Windows launcher relauncher: after resolving the executable's full path, strrchr(path, '\\') returned NULL — the canonical full path contains no backslash, so the launcher cannot compute the directory prefix to append JAVA_EXECUTABLE_NAME ('java'). It prints the message and exits 1. GetFullPathName always returns a drive-absolute path containing at least one backslash, so in practice this is a defensive check that fires only on degenerate results.
Source
Thrown at src/java.base/windows/native/launcher/relauncher.c:126
if (our_full_path_len == 0) {
fprintf(stderr, "failed to get the full path of the executable: %lu\n", GetLastError());
return 1;
}
char* our_full_path = malloc(our_full_path_len + 1);
if (our_full_path == NULL) {
perror("malloc failed");
return 1;
}
if (GetFullPathName(argv[0], our_full_path_len + 1, our_full_path, NULL) == 0) {
fprintf(stderr, "failed to get the full path of the executable: %lu\n", GetLastError());
return 1;
}
char *last_slash_pos = strrchr(our_full_path, '\\');
if (last_slash_pos == NULL) {
fprintf(stderr, "no '\\' found in the full path of the executable\n");
return 1;
}
size_t base_length = last_slash_pos - our_full_path + 1;
size_t java_path_length = base_length + strlen(JAVA_EXECUTABLE_NAME) + 1;
char *java_path = malloc(java_path_length);
if (java_path == NULL) {
perror("malloc failed");
return 1;
}
memcpy(java_path, our_full_path, base_length);
strcpy(java_path + base_length, JAVA_EXECUTABLE_NAME);
////////////////////////////////////////////////////////////////////////////
// Build the argument list: our executable name + launcher args + users args
View on GitHub (pinned to 88dfb74bbe)
Solutions
- Run java.exe in a clean environment (disable DLL injectors, overlays, screen recorders, compatibility shims) and retry
- Verify the same JDK image works on an unmodified Windows host to rule out the image itself
- Reinstall the JDK if the binary may be corrupted
- Report to the emulator/hooking vendor if this only happens under their environment
Defensive patterns
Strategy: validation
Prevention
- Run java.exe on genuine Windows filesystems; avoid emulators/hooking frameworks that alter Win32 path APIs
- Verify the JDK image checksums if the binary is suspected corrupted
When it happens
Trigger: GetFullPathName returning a malformed result (e.g. a device path or empty string due to a filesystem filter or emulation layer), or memory corruption of the buffer — the normal Windows API contract makes a backslash-free full path essentially impossible.
Common situations: Exotic environments: Windows Subsystem/compatibility shims, Wine or other emulators with imperfect GetFullPathName, corrupted process memory from injected DLLs (hooking/overlay software), or a truncated buffer.
Related errors
- failed to get the full path of the executable: %lu
- WaitForSingleObject failed: %lu
- GetExitCodeProcess failed: %lu
- no '/' found in the full path of the executable
- CreateProcess failed: %lu
AI-assisted analysis of openjdk/jdk@88dfb74bbe (2026-08-14).
Data as JSON: /api/errors/d4456e6a52dfb030.
Report an issue: GitHub.