Skip to content

Are the platforms stubs? #11

@gfour

Description

@gfour

Hello! Are the android.jar archives stubs of the Android APIs? According to Issue #4 that should not be the case but I disassemble classes at random and always see method bodies with the equivalent of throw new RuntimeException("Stub!").

For example, for android-25:

$ mkdir 25 && cd 25 && jar xf ../android-25/android.jar
$ javap -p -v -c android/system/Os.class
...
  public static int write(java.io.FileDescriptor, byte[], int, int) throws android.system.ErrnoException, java.io.InterruptedIOException;
    descriptor: (Ljava/io/FileDescriptor;[BII)I
    flags: ACC_PUBLIC, ACC_STATIC
    Code:
      stack=3, locals=4, args_size=4
         0: new           #2                  // class java/lang/RuntimeException
         3: dup
         4: ldc           #3                  // String Stub!
         6: invokespecial #4                  // Method java/lang/RuntimeException."<init>":(Ljava/lang/String;)V
         9: athrow
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions