Merge "AndroidKeyStore: return error code on error"

This commit is contained in:
Kenny Root
2013-02-05 00:20:46 +00:00
committed by Gerrit Code Review

View File

@ -243,7 +243,12 @@ public class KeyStore {
*/
public long getmtime(String key) {
try {
return mBinder.getmtime(key) * 1000L;
final long millis = mBinder.getmtime(key);
if (millis == -1L) {
return -1L;
}
return millis * 1000L;
} catch (RemoteException e) {
Log.w(TAG, "Cannot connect to keystore", e);
return -1L;