Skip to content

Commit 9dfca20

Browse files
jsharkeyAndroid (Google) Code Review
authored andcommitted
Merge "Print newly generated userId." into jb-mr1-dev
2 parents 810df89 + e6d3ccc commit 9dfca20

File tree

1 file changed

+4
-1
lines changed
  • cmds/pm/src/com/android/commands/pm

1 file changed

+4
-1
lines changed

cmds/pm/src/com/android/commands/pm/Pm.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -990,7 +990,10 @@ public void runCreateUser() {
990990
}
991991
name = arg;
992992
try {
993-
if (mUm.createUser(name, 0) == null) {
993+
final UserInfo info = mUm.createUser(name, 0);
994+
if (info != null) {
995+
System.out.println("Success: created user id " + info.id);
996+
} else {
994997
System.err.println("Error: couldn't create User.");
995998
}
996999
} catch (RemoteException e) {

0 commit comments

Comments
 (0)