]> git.ktnx.net Git - mobile-ledger.git/commitdiff
add version/API level info to the crash report
authorDamyan Ivanov <dam+mobileledger@ktnx.net>
Wed, 6 Mar 2019 15:18:55 +0000 (17:18 +0200)
committerDamyan Ivanov <dam+mobileledger@ktnx.net>
Wed, 6 Mar 2019 15:18:55 +0000 (17:18 +0200)
app/src/main/java/net/ktnx/mobileledger/ui/activity/CrashReportingActivity.java

index 7a16730beb3030d5504afd311157660f60f50a94..6a6f26db55a95a7d37aa05e98637d0a6f278a23a 100644 (file)
@@ -17,6 +17,7 @@
 
 package net.ktnx.mobileledger.ui.activity;
 
+import android.os.Build;
 import android.os.Bundle;
 import android.util.Log;
 
@@ -38,6 +39,9 @@ public abstract class CrashReportingActivity extends AppCompatActivity {
             public void uncaughtException(Thread t, Throwable e) {
                 StringWriter sw = new StringWriter();
                 PrintWriter pw = new PrintWriter(sw);
+
+                pw.format("OS version: %s; API level %d\n\n", Build.VERSION.RELEASE,
+                        Build.VERSION.SDK_INT);
                 e.printStackTrace(pw);
 
                 Log.e(null, sw.toString());