java-native-access / java-native-access/jna

Please add Windows Kernel Debug* Functions

Open
#1,256 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature request
Dominant language
Java
Stars
8.9k
Forks
1.7k
PR merge metrics
No merged PRs in 30d

Description

For suspending/resuming a process on Windows I would like to have various Windows Debug* functions added to JNA. I defined them as follows in my code:

import com.sun.jna.win32.StdCallLibrary;

public interface MyKernel32 extends StdCallLibrary {
	boolean DebugActiveProcess(int pid);

	boolean DebugSetProcessKillOnExit(boolean killOnExit);

	boolean DebugActiveProcessStop(int processId);
}

Is adding the definitions to C:\...\jna\contrib\platform\src\com\sun\jna\platform\win32\Kernel32.java as well as a documentation comment enough? Tests for such simple wrappers don't seem needed. Also, compiling JNA seems tedious so I'd rather not configure everything for such a simple addition which a JNA maintainer could do for me as well.

Thank you for your time.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in contrib/platform/src/com/sun/jna/platform/win32/Kernel32.java and compare the existing Windows API declarations and documentation comments. Review the requested DebugActiveProcess, DebugSetProcessKillOnExit, and DebugActiveProcessStop definitions, then verify that the JNA build accepts the additions; done means the declarations are available through Kernel32.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
operating-systems
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.