Status Update
Comments
pa...@google.com <pa...@google.com>
tn...@google.com <tn...@google.com> #2
ASharedMemory can no longer be mapped in child progress
ol...@google.com <ol...@google.com> #3
Device build details -- Device Make, Model, Android OS Version
Preconditions to reproduce the issue.
Please provide sample project.
Provide the bin file or apk if possible to depict it through JAVA API to reproduce the issue. Also mention the steps to be followed for reproducing the issue with the given sample project or apk.
Frequency
How frequently does this issue occur? (e.g 100% of the time, 10% of the time)
Expected output as per the apk shared.
What is the expected output?
Current output as per the apk shared.
What is the current output?
Android bug report (to be captured after reproducing the issue)
For steps to capture a bug report, please refer:
Alternate method
Navigate to “Developer options”, ensure “USB debugging” is enabled, then enable “Bug report shortcut”. Capture bug report by holding the power button and selecting the “Take bug report” option.
Note: Please upload the files to google drive and share the folder to android-bugreport@google.com, then share the link here.
tn...@google.com <tn...@google.com> #4
* Are you an Android developer?" (Y/N)
Yes
* Which Android Developer Preview build are you using? See Settings > About phone > Build number (for example RPP1.200123.000).
RPB3.200720.005
* Is this a regression from Android 10 to 11?
Yes
* What device are you using? (for example, Pixel 3 XL)
Pixel 2 API 30 emulated
* What are the steps to reproduce the problem? (Please provide the minimal reproducible test case.)
* Issue Category e.g. Framework (platform), NDK (platform), Hardware (CPU, GPU, Sensor, Camera), ART (platform), Runtime Permissions etc
NDK
* What was the expected result?
mmap in child progess success
*How frequently does this issue occur? (e.g 100% of the time, 10% of the time)
100% of the time
*Expected output as per the apk shared Relevant logcat output.
Code to reproduce the bug https://drive.google.com/file/d/1RKxloyiFUzVxniUHl_pGwB1C62hLAoKj/view?usp=sharing
Devices below android 11
E/MMap (24004): parent progess create ashmem success!! E/MMap (24004): parent progess mmap success!! E/MMap (24004): fork success on main process E/MMap (24024): fork child success E/MMap (24024): child process --child progess start!!--[/data/app/com.example.testmmap-2/lib/arm//libChild-mmap.so]--[26] E/MMap (24024): child process -- map ashmem region suceess !!! Device android 11 E MMap : parent progess create ashmem success!! E MMap : parent progess mmap success!! E MMap : fork success on main process E MMap : child progess start!!--[/data/app/~~dwoB2cD-fsG1UYLML_cKLw==/com.example.testmmap-m50nMorgvlONu3i6uNFhJw==/lib/x86//libChild-mmap.so]--[54] E MMap : child process --failed to map ashmem region: Bad file descriptor
* What was the actual result?
mmap in child progess failed
Description
Android support annotations version: 23.1.1
Android studio version: 1.5.1
@IntDef or @StringDef do not show an error when assigning an invalid constant to a variable. Also, the annotation is not tracked for fields.
For instance
private static final int TREE_PATH_ONE = 1;
private static final int TREE_PATH_TWO = 2;
private static final int TREE_PATH_THREE = 3;
@IntDef(value = {
TREE_PATH_ONE,
TREE_PATH_TWO,
TREE_PATH_THREE
})
@Retention(RetentionPolicy.SOURCE)
private @interface Tree {
}
@Tree
private int mTreeField = TREE_PATH_ONE;
private void problem1() {
@Tree int treeInvalid = 12; // Not marked as an error. Lint does not seem to track @IntDef
// annotations for variables or fields
//@Tree int treeValid = TREE_PATH_ONE;
problem2(mTreeField); // Falsely marked as an error. Lint does not track @IntDef annotations
// fields so it does not know the mTreeField is actually a @Tree
}
private void problem2(@Tree int tree) {
}