From c497501bc60077be27b3a03c387a8225732ce1bf Mon Sep 17 00:00:00 2001 From: "Christian P. MOMON" Date: Sun, 13 Sep 2020 00:46:44 +0200 Subject: [PATCH] Fixed NullPointerException with IllegalArgumentException. --- src/fr/devinsy/strings/StringListInputStream.java | 4 ++-- src/fr/devinsy/strings/StringListWriter.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/fr/devinsy/strings/StringListInputStream.java b/src/fr/devinsy/strings/StringListInputStream.java index 0d235a9..9b49a9b 100644 --- a/src/fr/devinsy/strings/StringListInputStream.java +++ b/src/fr/devinsy/strings/StringListInputStream.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2013-2015,2017-2018 Christian Pierre MOMON + * Copyright (C) 2013-2020 Christian Pierre MOMON * * This file is part of Devinsy-strings. * @@ -57,7 +57,7 @@ public class StringListInputStream extends InputStream { if (source == null) { - throw new NullPointerException("source is null."); + throw new IllegalArgumentException("source is null."); } else { diff --git a/src/fr/devinsy/strings/StringListWriter.java b/src/fr/devinsy/strings/StringListWriter.java index 4f58113..25b02b4 100644 --- a/src/fr/devinsy/strings/StringListWriter.java +++ b/src/fr/devinsy/strings/StringListWriter.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2013-2018 Christian Pierre MOMON + * Copyright (C) 2013-2020 Christian Pierre MOMON * * This file is part of Devinsy-strings. * @@ -57,7 +57,7 @@ public class StringListWriter extends Writer { if (target == null) { - throw new NullPointerException("target is null."); + throw new IllegalArgumentException("target is null."); } else {