OSDN Git Service

Fix StringIndexOutOfBoundsException in PackageManagerService
authorBjorn Bringert <bringert@android.com>
Fri, 29 Jan 2010 12:11:30 +0000 (12:11 +0000)
committerBjorn Bringert <bringert@android.com>
Fri, 29 Jan 2010 12:29:41 +0000 (12:29 +0000)
commit5fd5bfe942a03a2a0f8b55e78138e5ca7d578c6b
treeb2ed5440a50415eb8945387125c631440953b8d2
parent784d53e79bab67e6b08b4bfc9a2dc75cfcba9772
Fix StringIndexOutOfBoundsException in PackageManagerService

The method packageManagerService.getNextCodePath(String oldCodePath,
String prefix, String suffix) threw StringIndexOutOfBoundsException if
oldCodePath does not contain prefix, and prefix is longer than
oldCodePath, or if the preix and suffix overlap.

Fixes http://b/issue?id=2404232

Change-Id: Ib8abb16f8bfd08f607476d9289f46d170c43a076
services/java/com/android/server/PackageManagerService.java