diff options
author | Arne Schwabe <arne@rfc2549.org> | 2015-03-19 15:16:25 +0100 |
---|---|---|
committer | Arne Schwabe <arne@rfc2549.org> | 2015-03-19 15:16:25 +0100 |
commit | ea8c819949d3f3eeb77587d78eef24d94732e8d5 (patch) | |
tree | 2f6a3aa04cc05192b5dd428841f239804b804251 /main/src | |
parent | b05d9f664f489c963ccd9bd69f7c1014bcc8a9c6 (diff) |
Fix formatting of log messages if no context is available (Closes schwabe/ics-openvpn-old-repo-do-not-use#13)
Diffstat (limited to 'main/src')
-rw-r--r-- | main/src/main/java/de/blinkt/openvpn/core/VpnStatus.java | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/main/src/main/java/de/blinkt/openvpn/core/VpnStatus.java b/main/src/main/java/de/blinkt/openvpn/core/VpnStatus.java index d1269380..73f9dff5 100644 --- a/main/src/main/java/de/blinkt/openvpn/core/VpnStatus.java +++ b/main/src/main/java/de/blinkt/openvpn/core/VpnStatus.java @@ -14,6 +14,10 @@ import android.content.pm.Signature; import android.os.Build; import android.os.Parcel; import android.os.Parcelable; +import android.text.TextUtils; + +import org.w3c.dom.Text; + import de.blinkt.openvpn.R; import java.io.ByteArrayInputStream; @@ -218,12 +222,12 @@ public class VpnStatus { if(mArgs == null) return c.getString(mRessourceId); else - return c.getString(mRessourceId,mArgs); + return c.getString(mRessourceId, mArgs); } else { String str = String.format(Locale.ENGLISH,"Log (no context) resid %d", mRessourceId); if(mArgs !=null) - for(Object o:mArgs) - str += "|" + o.toString(); + str += TextUtils.join(" ", mArgs); + return str; } |