aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/util/Properties.java
diff options
context:
space:
mode:
Diffstat (limited to 'libjava/java/util/Properties.java')
-rw-r--r--libjava/java/util/Properties.java11
1 files changed, 4 insertions, 7 deletions
diff --git a/libjava/java/util/Properties.java b/libjava/java/util/Properties.java
index 2f44289..8f0cbab 100644
--- a/libjava/java/util/Properties.java
+++ b/libjava/java/util/Properties.java
@@ -188,17 +188,14 @@ label = Name:\\u0020</pre>
{
char c = 0;
int pos = 0;
- // If empty line or begins with a comment character, skip this line.
- if (line.length() == 0
- || line.charAt(0) == '#' || line.charAt(0) == '!')
- continue;
-
+ // Leading whitespaces must be deleted first.
while (pos < line.length()
&& Character.isWhitespace(c = line.charAt(pos)))
pos++;
- // If line is empty skip this line.
- if (pos == line.length())
+ // If empty line or begins with a comment character, skip this line.
+ if (line.length() == 0
+ || line.charAt(0) == '#' || line.charAt(0) == '!')
continue;
// The characters up to the next Whitespace, ':', or '='