I'm playing with AOSP, and trying to apply OTA package
1). I built AOSP for Google Pixel and installed it
2). I created simple app, which downloads OTA package, and trying to apply it (It's based on this article: http://jhshi.me/2013/12/13/how-to-apply-downloaded-ota-package/index.html)
I'm calling
RecoverySystem.installPackage(getContext(), file);
, and it gets me
java.lang.NullPointerException: Attempt to invoke interface method 'boolean android.os.IRecoverySystem.setupBcb(java.lang.String)' on a null object reference
at android.os.RecoverySystem.setupBcb(RecoverySystem.java:895)
at android.os.RecoverySystem.installPackage(RecoverySystem.java:496)
at android.os.RecoverySystem.installPackage(RecoverySystem.java:421)
Can anyone point me how to fix it please?