private static String fixPath(String path) {
    /*
     * If the path separator is \ (like on windows), we convert the
     * path to a standard '/' separated path.
     */
    if (File.separatorChar == '\\') {
      path = path.replace('\\', '/');
    }

    int index = path.lastIndexOf("/./");

    if (index != -1) {
      return path.substring(index + 3);
    }

    if (path.startsWith("./")) {
      return path.substring(2);
    }

    return path;
  }
Returns the "fixed" version of a given file path, suitable for use as a path within a {@code
.jar} file and for checking against a classfile-internal "this class" name. This looks for the
last instance of the substring {@code "/./"} within the path, and if it finds it, it takes the
portion after to be the fixed path. If that isn't found but the path starts with {@code "./"},
then that prefix is removed and the rest is return. If neither of these is the case, this
method returns its argument.

@param path {@code non-null;} the path to "fix"
@return {@code non-null;} the fixed version (which might be the same as the given {@code path})
android/android_framework/dex-maker/src/main/java/com/android/dx/command/dexer/Main.java