Skip to content
This repository has been archived by the owner on Jun 19, 2024. It is now read-only.

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
TIMER-err committed Mar 9, 2024
1 parent 50af094 commit 33ce9f2
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions InjectUI/src/cn/yapeteam/injector/MainFrame.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
public class MainFrame extends JFrame {
private JPanel panel;
private JButton inject;
private JComboBox<String> method;
private JComboBox<String> process;
private JProgressBar progressBar1;
private JProgressBar progressBar2;
Expand Down Expand Up @@ -49,7 +48,7 @@ public void windowClosing(WindowEvent e) {

getRootPane().setDefaultButton(inject);
inject.addActionListener(e -> {
if (!targets.isEmpty() && process.getSelectedIndex() != -1 && method.getSelectedIndex() != -1) {
if (!targets.isEmpty() && process.getSelectedIndex() != -1) {
int pid = targets.get(process.getSelectedIndex()).b;
try {
VirtualMachine virtualMachine = VirtualMachine.attach(String.valueOf(pid));
Expand All @@ -66,7 +65,6 @@ public void windowClosing(WindowEvent e) {
return;
}
process.setVisible(false);
method.setVisible(false);
inject.setVisible(false);
}
});
Expand Down

0 comments on commit 33ce9f2

Please sign in to comment.