Skip to content

Commit 71adeca

Browse files
committed
Don't allow the parallelism to be smaller than 1.
1 parent 6889229 commit 71adeca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

MSFragger-GUI/src/com/dmtavt/fragpipe/tabs/TabWorkflow.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ private JPanel createPanelOptions() {
430430
uiSpinnerRam = new UiSpinnerInt(0, 0, 1024, 1, 3);
431431
FormEntry feRam = fe(uiSpinnerRam, "ram").label("RAM (GB, 0=auto)").tooltip("Leave at zero to use a reasonable amount automatically").create();
432432
final int maxProcessors = 128;
433-
uiSpinnerThreads = new UiSpinnerInt(Math.min(Runtime.getRuntime().availableProcessors() - 1, maxProcessors), 0, maxProcessors, 1);
433+
uiSpinnerThreads = new UiSpinnerInt(Math.max(1, Math.min(Runtime.getRuntime().availableProcessors() - 1, maxProcessors)), 0, maxProcessors, 1);
434434
FormEntry feThreads = fe(uiSpinnerThreads, "threads").label("Parallelism").create();
435435

436436
mu.add(p, feRam.label()).split();

0 commit comments

Comments
 (0)