summaryrefslogtreecommitdiff
path: root/src/de/blinkt/openvpn/core/ConfigParser.java
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2014-01-11 15:22:26 +0100
committerArne Schwabe <arne@rfc2549.org>2014-01-11 15:22:26 +0100
commit383044cf103dac085463d07beb5f3ab495a08453 (patch)
treee01a581a179ff1ceb32dc327a731f1fa8f7f89c7 /src/de/blinkt/openvpn/core/ConfigParser.java
parentdd6f4ac1248e73106cf54ba78856dc27265bc5e1 (diff)
Update Openvpn, fix config parser for trailing whitespace on <foo> and </bar> optionsv0.6.4
Diffstat (limited to 'src/de/blinkt/openvpn/core/ConfigParser.java')
-rw-r--r--src/de/blinkt/openvpn/core/ConfigParser.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/de/blinkt/openvpn/core/ConfigParser.java b/src/de/blinkt/openvpn/core/ConfigParser.java
index 7b6b4a91..103c208b 100644
--- a/src/de/blinkt/openvpn/core/ConfigParser.java
+++ b/src/de/blinkt/openvpn/core/ConfigParser.java
@@ -71,7 +71,7 @@ public class ConfigParser {
}
private void checkinlinefile(Vector<String> args, BufferedReader br) throws IOException, ConfigParseError {
- String arg0 = args.get(0);
+ String arg0 = args.get(0).trim();
// CHeck for <foo>
if(arg0.startsWith("<") && arg0.endsWith(">")) {
String argname = arg0.substring(1, arg0.length()-1);
@@ -83,7 +83,7 @@ public class ConfigParser {
if(line==null){
throw new ConfigParseError(String.format("No endtag </%s> for starttag <%s> found",argname,argname));
}
- if(line.equals(endtag))
+ if(line.trim().equals(endtag))
break;
else {
inlinefile+=line;