Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d4ec5ae5 authored by Dianne Hackborn's avatar Dianne Hackborn Committed by Android (Google) Code Review
Browse files

Merge "Improve multi-user app management." into jb-mr1-dev

parents 7b3ca5bb 0c380495
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -432,7 +432,7 @@ int protect(char *pkgname, gid_t gid)
    return 0;
}

int get_size(const char *pkgname, const char *apkpath,
int get_size(const char *pkgname, int persona, const char *apkpath,
             const char *fwdlock_apkpath, const char *asecpath,
             int64_t *_codesize, int64_t *_datasize, int64_t *_cachesize,
             int64_t* _asecsize)
@@ -479,7 +479,7 @@ int get_size(const char *pkgname, const char *apkpath,
        }
    }

    if (create_pkg_path(path, pkgname, PKG_DIR_POSTFIX, 0)) {
    if (create_pkg_path(path, pkgname, PKG_DIR_POSTFIX, persona)) {
        goto done;
    }

+4 −3
Original line number Diff line number Diff line
@@ -85,8 +85,9 @@ static int do_get_size(char **arg, char reply[REPLY_MAX])
    int64_t asecsize = 0;
    int res = 0;

        /* pkgdir, apkpath */
    res = get_size(arg[0], arg[1], arg[2], arg[3], &codesize, &datasize, &cachesize, &asecsize);
        /* pkgdir, persona, apkpath */
    res = get_size(arg[0], atoi(arg[1]), arg[2], arg[3], arg[4],
            &codesize, &datasize, &cachesize, &asecsize);

    /*
     * Each int64_t can take up 22 characters printed out. Make sure it
@@ -150,7 +151,7 @@ struct cmdinfo cmds[] = {
    { "freecache",            1, do_free_cache },
    { "rmcache",              1, do_rm_cache },
    { "protect",              2, do_protect },
    { "getsize",              4, do_get_size },
    { "getsize",              5, do_get_size },
    { "rmuserdata",           2, do_rm_user_data },
    { "movefiles",            0, do_movefiles },
    { "linklib",              2, do_linklib },
+1 −1
Original line number Diff line number Diff line
@@ -199,7 +199,7 @@ int delete_cache(const char *pkgname);
int move_dex(const char *src, const char *dst);
int rm_dex(const char *path);
int protect(char *pkgname, gid_t gid);
int get_size(const char *pkgname, const char *apkpath, const char *fwdlock_apkpath,
int get_size(const char *pkgname, int persona, const char *apkpath, const char *fwdlock_apkpath,
             const char *asecpath, int64_t *codesize, int64_t *datasize, int64_t *cachesize,
             int64_t *asecsize);
int free_cache(int64_t free_size);
+7 −0
Original line number Diff line number Diff line
@@ -1377,6 +1377,13 @@ public class ActivityManager {
         */
        public static final int FLAG_PERSISTENT = 1<<1;

        /**
         * Constant for {@link #flags}: this process is associated with a
         * persistent system app.
         * @hide
         */
        public static final int FLAG_HAS_ACTIVITIES = 1<<2;

        /**
         * Flags of information.  May be any of
         * {@link #FLAG_CANT_SAVE_STATE}.
+3 −3
Original line number Diff line number Diff line
@@ -1079,10 +1079,10 @@ final class ApplicationPackageManager extends PackageManager {
    }

    @Override
    public void getPackageSizeInfo(String packageName,
    public void getPackageSizeInfo(String packageName, int userHandle,
            IPackageStatsObserver observer) {
        try {
            mPM.getPackageSizeInfo(packageName, observer);
            mPM.getPackageSizeInfo(packageName, userHandle, observer);
        } catch (RemoteException e) {
            // Should never happen!
        }
Loading