Commit f0d274c
authored
The app is crashed, if any low memory issue occured
If any crash occurred due toa low memory issue, we just prevent the app from crashing and reload the webview.
To test this issue please execute the following code
```
<script>
function crashWebView() {
try {
let a = [];
while (true) {
a.push(new Array(1000000).fill('*'));
}
} catch (e) {
console.log('Crashed!', e);
}
}
crashWebView();
</script>
```1 parent a054aa5 commit f0d274c
File tree
1 file changed
+13
-0
lines changed- android/capacitor/src/main/java/com/getcapacitor
1 file changed
+13
-0
lines changedLines changed: 13 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
| 100 | + | |
100 | 101 | | |
101 | 102 | | |
102 | 103 | | |
| |||
106 | 107 | | |
107 | 108 | | |
108 | 109 | | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
109 | 122 | | |
110 | 123 | | |
111 | 124 | | |
0 commit comments