Commit 52e5506
committed
fix: Avoid stale var cache and poll for userspace
Force direct device queries and clear cached fastboot vars to avoid stale values after reboot/mode changes. IsUserspace() now calls GetVar(..., useCache:false). After rebooting to fastboot, _varCache is cleared before reconnect to ensure fresh vars. Reboot-to-userspace now polls up to 30s (1s intervals) for the device to report userspace, throwing an error if it doesn't appear, and preserves the existing small delay to match AOSP behavior.1 parent 345097e commit 52e5506
1 file changed
+19
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
| 42 | + | |
| 43 | + | |
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| |||
343 | 344 | | |
344 | 345 | | |
345 | 346 | | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
346 | 350 | | |
347 | 351 | | |
348 | 352 | | |
| |||
399 | 403 | | |
400 | 404 | | |
401 | 405 | | |
402 | | - | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
403 | 420 | | |
404 | 421 | | |
405 | 422 | | |
| |||
0 commit comments