summaryrefslogtreecommitdiffstats
path: root/core/java/android/app/backup
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2014-04-28 18:36:53 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-04-28 18:36:53 +0000
commit3ce4f3d0af8b20f915631ab927aafa76a6105135 (patch)
treed3068a5c1435a3dc5eb8e8eaa7999591e7df88f0 /core/java/android/app/backup
parentc6d0dc896438d8918f4f985513e92be9b4d69e87 (diff)
parent685a0a72d445515167a2071330679cdf9b53a62d (diff)
downloadframeworks_base-3ce4f3d0af8b20f915631ab927aafa76a6105135.zip
frameworks_base-3ce4f3d0af8b20f915631ab927aafa76a6105135.tar.gz
frameworks_base-3ce4f3d0af8b20f915631ab927aafa76a6105135.tar.bz2
am 685a0a72: am bbd87eb9: Merge "Track libcore.os\' move to android.system."
* commit '685a0a72d445515167a2071330679cdf9b53a62d': Track libcore.os' move to android.system.
Diffstat (limited to 'core/java/android/app/backup')
-rw-r--r--core/java/android/app/backup/BackupAgent.java15
-rw-r--r--core/java/android/app/backup/FullBackup.java7
2 files changed, 10 insertions, 12 deletions
diff --git a/core/java/android/app/backup/BackupAgent.java b/core/java/android/app/backup/BackupAgent.java
index 67c772b..70a3797 100644
--- a/core/java/android/app/backup/BackupAgent.java
+++ b/core/java/android/app/backup/BackupAgent.java
@@ -29,6 +29,10 @@ import android.os.Looper;
import android.os.ParcelFileDescriptor;
import android.os.Process;
import android.os.RemoteException;
+import android.system.ErrnoException;
+import android.system.Os;
+import android.system.OsConstants;
+import android.system.StructStat;
import android.util.Log;
import java.io.File;
@@ -38,11 +42,6 @@ import java.util.HashSet;
import java.util.LinkedList;
import java.util.concurrent.CountDownLatch;
-import libcore.io.ErrnoException;
-import libcore.io.Libcore;
-import libcore.io.OsConstants;
-import libcore.io.StructStat;
-
/**
* Provides the central interface between an
* application and Android's data backup infrastructure. An application that wishes
@@ -191,7 +190,7 @@ public abstract class BackupAgent extends ContextWrapper {
* the key supplied as part of the entity. Writing an entity with a negative
* data size instructs the transport to delete whatever entity currently exists
* under that key from the remote data set.
- *
+ *
* @param oldState An open, read-only ParcelFileDescriptor pointing to the
* last backup state provided by the application. May be
* <code>null</code>, in which case no prior state is being
@@ -222,7 +221,7 @@ public abstract class BackupAgent extends ContextWrapper {
* onRestore() throws an exception, the OS will assume that the
* application's data may now be in an incoherent state, and will clear it
* before proceeding.
- *
+ *
* @param data A structured wrapper around an open, read-only
* file descriptor pointing to a full snapshot of the
* application's data. The application should consume every
@@ -412,7 +411,7 @@ public abstract class BackupAgent extends ContextWrapper {
}
// If it's a directory, enqueue its contents for scanning.
- StructStat stat = Libcore.os.lstat(filePath);
+ StructStat stat = Os.lstat(filePath);
if (OsConstants.S_ISLNK(stat.st_mode)) {
if (DEBUG) Log.i(TAG, "Symlink (skipping)!: " + file);
continue;
diff --git a/core/java/android/app/backup/FullBackup.java b/core/java/android/app/backup/FullBackup.java
index cb0737e..477285d 100644
--- a/core/java/android/app/backup/FullBackup.java
+++ b/core/java/android/app/backup/FullBackup.java
@@ -20,6 +20,8 @@ import android.content.Context;
import android.content.pm.ApplicationInfo;
import android.content.pm.PackageManager;
import android.os.ParcelFileDescriptor;
+import android.system.ErrnoException;
+import android.system.Os;
import android.util.Log;
import java.io.File;
@@ -27,9 +29,6 @@ import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
-import libcore.io.ErrnoException;
-import libcore.io.Libcore;
-
/**
* Global constant definitions et cetera related to the full-backup-to-fd
* binary format. Nothing in this namespace is part of any API; it's all
@@ -150,7 +149,7 @@ public class FullBackup {
try {
// explicitly prevent emplacement of files accessible by outside apps
mode &= 0700;
- Libcore.os.chmod(outFile.getPath(), (int)mode);
+ Os.chmod(outFile.getPath(), (int)mode);
} catch (ErrnoException e) {
e.rethrowAsIOException();
}