Stop emulator when both, gpu and snapshots are on.

This is a temporary solution fixing emulator crash due to the difficulties in
implementing GPU state save to and reload from snapshot.

Change-Id: Id62830d3447538472d3c7a83ade97f4f09dfaa06
diff --git a/android/main.c b/android/main.c
index c56bb5c..b7421a1 100644
--- a/android/main.c
+++ b/android/main.c
@@ -1155,6 +1155,15 @@
         }
     }
 
+    /* Quit emulator on condition that both, gpu and snapstorage are on. This is
+     * a temporary solution preventing the emulator from crashing until GPU state
+     * can be properly saved / resored in snapshot file. */
+    if (hw->hw_gpu_enabled && opts->snapstorage && (!opts->no_snapshot_load ||
+                                                    !opts->no_snapshot_save)) {
+        derror("Snapshots and gpu are mutually exclusive at this point. Please turn one of them off, and restart the emulator.");
+        exit(1);
+    }
+
     if (opts->fake_camera) {
         if (!strcmp(opts->fake_camera, "back") ||
             !strcmp(opts->fake_camera, "front") ||