From b1104da01efa1f0b0daa15b288f8f68848c9fcd8 Mon Sep 17 00:00:00 2001 From: Marc-Andre Laperle Date: Thu, 5 Nov 2015 22:30:21 -0500 Subject: [PATCH] Clarify null handling in javadoc of ProcessClosure constructor The javadoc of ProcessClosure specifies that outputStream/errorStream "Can be null, if not interested in reading the output" but that's not correct: passing null triggers NPEs. This patch updates the javadoc to specify that null is not handled. Change-Id: Iea65486cc938d1f3bf7f0beb479b2329c9f0ecdc Signed-off-by: Marc-Andre Laperle --- .../src/org/eclipse/cdt/internal/core/ProcessClosure.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/core/ProcessClosure.java b/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/core/ProcessClosure.java index 725b8c4c1a3..bb8b6e55eaa 100644 --- a/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/core/ProcessClosure.java +++ b/core/org.eclipse.cdt.core/src/org/eclipse/cdt/internal/core/ProcessClosure.java @@ -117,11 +117,9 @@ public class ProcessClosure { * console document. * * @param outputStream - * prcess stdout is written to this stream. Can be - * null, if not interested in reading the output + * prcess stdout is written to this stream. Cannot be null. * @param errorStream - * prcess stderr is written to this stream. Can be - * null, if not interested in reading the output + * prcess stderr is written to this stream. Cannot be null. */ public ProcessClosure(Process process, OutputStream outputStream, OutputStream errorStream) { fProcess = process;