| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Bug: 63766886
Test: ran CTS tests
Change-Id: I1173f67d6fb41494d6d069cc7cfc0c2b0dcc1725
(cherry picked from commit 8a1db2e3fa16bce83856a3a8920f8820fe942fce)
CVE-2018-9379
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With WRITE_MEDIA_STORAGE permission, MediaProvider can access external
storage across users.
Access should be rejected for content in other user's external storage
if the caller has no WRITE_MEDIA_STORAGE/INTERACT_ACROSS_USERS
Test: manual + android.provider.cts.MediaStore_FilesTest
Bug: 34114752
AOSP-Change-Id: I577cc33574185657592246c1103df4174ff3acf6
(cherry picked from commit cc1cecc9be51f9655d9acdf1729345d16f078c21)
CVE-2017-0669
Change-Id: Id986720c8265eaba91c809277b97d0ff4a2fc6ba
|
|
|
|
|
|
|
|
| |
catch StaleDataException and IllegalStateException when use
ringtonManger to get rington to avoid crash.
Change-Id: I6db82fd61de5dcb799efdd51c39b0433dcdb60a0
CRs-Fixed: 1042275
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
openFileDescriptor or openOutputStream will call openFile in MediaProvider.
And the parent dir of the caller's url is created by openFile.
But MediaStore_FilesTest expect that the dir does not exists.
So the test case fail.
Remove the function of creating the dir to make MediaStore_FilesTest
successfully in openFile. And create the dir in the request function.
Change-Id: Id497e3ed70f41ca0a3a83a496ff82a5b3d33ca77
CRs-Fixed: 1020200
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The photo is edited and save to new file in gallery,
the thumbnail of the new photo is generated and saved at the same time.
But the directory of thumbnails is not created, and the thumbnail can't save.
So the thumbnail displays incorrectly in Documents's Recent list.
Check the directory of thumbnails whether create,
if not create it at first to make the thumbnails save successfully.
Change-Id: I110a7bf568750cc9a0350d99f0a68f6b18c14fbd
CRs-Fixed: 994316
|
|
|
|
|
|
|
|
| |
method getCompressedAlbumArt() return null if file path is null,
because it will occur NullPointerException.
Change-Id: I051636bd844764cc64aa663f2a1e1ecc621b672c
CRs-Fixed: 994948
|
|
|
|
|
|
|
|
|
| |
The SQLiteDiskIOExcept occur from monkey test.
Catch the expcetion.
Change-Id: I9d8f95449ac1d635e4b7c5267ba92ec7e6f76a39
CRs-Fixed: 961398
|
|\
| |
| |
| |
| |
| | |
https://android.googlesource.com/platform/packages/providers/MediaProvider into HEAD
Android 6.0.1 release 3
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Now that we're putting the media roots up front and center through
the Settings > Storage UI, users have an expectation of deleting
media to free up disk space.
Bug: 24450605
Change-Id: I38e1b021db2bf1f42a43f81f609818df905a0c0b
|
| |
| |
| |
| | |
Change-Id: I77fe9e09b523bcba68dd2409def68acb715ca33c
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When device is connected as MTP mode and user opens folder
/sdcard/Pictures/Screenshots/ in windows system and captures new
screenshot, image information is always shown as 0 KB
Issue: https://code.google.com/p/android/issues/detail?id=56204
Change-Id: I0e633efc7a5b213e519d4de6b137992c5bfe8738
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Check if path is not null to avoid a java.lang.NullPointerException.
If path is null, the following exception stack trace will be thrown:
java.lang.NullPointerException: Attempt to invoke virtual method 'char[] java.lang.String.toCharArray()' on a null object reference
at java.io.File.fixSlashes(File.java:185)
at java.io.File.<init>(File.java:134)
at com.android.providers.media.MediaProvider.getCompressedAlbumArt(MediaProvider.java:4846)
at com.android.providers.media.MediaProvider.makeThumbInternal(MediaProvider.java:5015)
at com.android.providers.media.MediaProvider.getThumb(MediaProvider.java:5011)
at com.android.providers.media.MediaProvider.openFile(MediaProvider.java:4601)
at android.content.ContentProvider.openAssetFile(ContentProvider.java:1334)
at android.content.ContentProvider.openTypedAssetFile(ContentProvider.java:1514)
at android.content.ContentProvider.openTypedAssetFile(ContentProvider.java:1580)
at android.content.ContentProvider$Transport.openTypedAssetFile(ContentProvider.java:391)
at android.content.ContentProviderNative.onTransact(ContentProviderNative.java:312)
at android.os.Binder.execTransact(Binder.java:446)
Change-Id: Ie27605590db20e0e4e12095d32864a246cc25573
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Usage:
Intent intent = new Intent(RingtoneManager.ACTION_RINGTONE_PICKER);
intent.putExtra(RingtoneManager.EXTRA_RINGTONE_TYPE, RingtoneManager.TYPE_ALARM);
intent.putExtra(RingtoneManager.EXTRA_RINGTONE_DIALOG_THEME, R.style.CustomDialogTheme); <<< Add your custom dialog theme here
startActivityForResult(intent, 0);
Style Usage:
Define an style that inherits from an android base theme
<style name="CustomDialogThemeDark" parent="@*android:style/Theme.Holo.Dialog.Alert">
or
<style name="CustomDialogThemeLight" parent="@*android:style/Theme.Holo.Light.Dialog.Alert">
or define your own dialog style
Depends on http://review.cyanogenmod.org/#/c/61392
Change-Id: I409eba2674f68386cdd20b74fc3ea42b8e81d111
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
|
|/
|
|
|
|
|
|
|
| |
"OK" and "Cancel" button's click event response at the same time
lead to FATAL EXCEPTION. Make the click events do not happen at
the same time.
CRs-Fixed: 513752
Change-Id: I92fc1dc15be42d0bd9fe54f41fdbb26b3ca4b85c
|
|
|
|
|
|
|
|
|
|
| |
Previously, MediaProvider would only create default directories once
during the lifetime of a device. However, we're now regularly wiping
storage devices when formatted as internal or portable, so we should
create these directories the first time we encounter each device.
Bug: 23329611
Change-Id: I71f8e9b47ad28c9883925c61f31ae61a070cc9b4
|
|
|
|
|
|
|
|
|
|
|
|
| |
Devices that use physical media as their primary storage may not
have that storage mounted by the time that MediaProvider is started,
which means we'd snapshot a stale primary storage path.
To fix this, refresh those paths as volumes are mounted or unmounted
over time. Also fix logic that detects secondary storage devices.
Bug: 22629557
Change-Id: I3c6b057ce082318e1b28e261c953a436da42e36f
|
|
|
|
|
|
|
|
|
|
|
|
| |
The media provider can call into the downloads provider which
runs in the same process from an IPC. In this case the
permission and ap ops checks in the downloads provider will
be verified against the caller of the media provider instead
of against the media provider itself.
bug:22629557
Change-Id: I444a2db96353f50c60cd1d7bb20538ab7d463a1e
|
|\ |
|
| |
| |
| |
| |
| | |
Bug: 22519119
Change-Id: I8aff294201dfd8ec46ff3d30e4ceecea1346f29b
|
|/
|
|
|
| |
Bug: 22753582
Change-Id: I73f3e8b7bc3fabab92909a183fcc71be7bb667b4
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When enforcing various storage permissions, check associated app-ops
to see if they've been revoked. We're okay throwing outright, since
Environment already told the app that volumes are unmounted, so they
have no business poking around.
Read/write sanity checking should only be relaxed to group-level for
files living on storage devices; continue using globally readable
flags for all other files.
Refresh storage paths whenever volumes change.
Bug: 22718722
Change-Id: I8640998f490550b4cd3a9b27bb6cb1a658bd102a
|
|
|
|
|
|
|
|
|
| |
The new storage layout used for runtime permissions uses the "group"
ACL for enforcing access, and the "other" ACL is usually masked off
completely.
Bug: 22525550
Change-Id: I29b48cc3425ccfc8d3ff5ec323c8dc50be104878
|
|
|
|
|
|
|
|
| |
Return START_REDELIVER_INTENT to make sure we always get the intent
if we're ever killed and restarted.
Bug: 22349167
Change-Id: I696284b8d55a8c8d1fb2362cd769981ae0d45366
|
|
|
|
|
|
|
|
|
| |
It ends up that MediaProvider is persisting MTP storage IDs in its
database, so we need to make sure we generate stable IDs over time,
otherwise we can end up looking into a black hole.
Bug: 22256092
Change-Id: Ia419c37f87c7c0aa59ef0de530fd219c82988f6c
|
|
|
|
|
|
| |
Bug 21581123
Change-Id: I765e047ea65b3b6e19b3814502246a31be1b41b3
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When adb is disabled, the default usb mode would be "none", which
would turn off the driver and prevent UsbDeviceManager from receiving
any new USB connect / disconnect messages. This prevents the user
from ever enabling MTP and sharing data when adb is turned off.
As discussed in bug 21429947, we work around this problem by keeping
the USB driver in MTP mode most of the time, so that we continue to
receive USB connect / disconnect messages.
To avoid leaking confidential user photos, this change honors the
unlock state sent to us by the UsbDeviceManager code. We only expose
user data if explicitly authorized by the user. MTP being enabled
is decoupled from data being exposed on the USB connection.
Bug: 21429947
Change-Id: I495011aa4e3e18c5e5e6fe7b9d0e1a3efe747ee7
|
|
|
|
|
|
|
|
|
|
| |
Read EXTRA_RINGTONE_AUDIO_ATTRIBUTES_FLAGS from intent to change
the AudioAttributes flags on the Ringtone instance used to play
the selected ringtone.
Bug 19407114
Change-Id: I2d923ef27e8db19b2560a129ba2462c90a07a997
|
|
|
|
|
|
|
|
| |
We can now have primary emulated removeable storage, which causes
this code to be upset.
Bug: 19993667
Change-Id: Id806c5d41ede6e040af9a48496b9e103a9c75962
|
|
|
|
|
| |
Bug: 19993667
Change-Id: I6380ac08f2eb91af81277d0ace42943e20112b2d
|
|\
| |
| |
| |
| |
| |
| | |
prevent crash.
* commit 'fe619b536938e7c2835c4858b96983ff7d297932':
Check mCurrentThumbRequest.mPath to prevent crash.
|
| |\
| | |
| | |
| | |
| | | |
* commit '1baeeea4c716b650346030e6da7bee38609028cf':
Check mCurrentThumbRequest.mPath to prevent crash.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Bug: 19246412
Change-Id: I25c2f09ded0527ac062d9c8a57adf3aa7639ea76
|
|/ /
| |
| |
| | |
Change-Id: Ib91d67a952582090d1fccf1dc8e7902edad2dfa5
|
|\ \
| |/
|/|
| |
| |
| |
| | |
Don\'t notify MTP."
* commit '9200927da3277128cfb517d54cea8be52d6ae602':
MediaProvider: When insert files to "internal.db", Don't notify MTP.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Don't notify MTP.
Steps to Reproduce:
1. Connect DUT to Win7 PC via USB cable.
2. Do Factory reset, don't unplug the USB cable during the reset.
->DUT will reboot automatically after factory reset.
3. After DUT enters the system, transfer some files to the DUT by MTP or
take some photos by Camera.
Expected Results:
Read DUT files normally on Win7 PC.
Actual Results:
The files transferred by MTP are named as "Local Disk" on the PC.
And the photos token by Camera can not be showed.
After file is inserted into "internal.db", don't notify MTP. If notify,
PC will get no data from DUT because MtpServer will only query
file's info from "external.db" and after PC gets no data so many
times, it won't send "GetObjectPropList" request to DUT, that will
cause "Local Disk" showed on the PC side.
Change-Id: I6cb364158dbda8b267bdfbf6663d0682f7d4d6cb
Signed-off-by: xiaochao <xiaochao.huang@intel.com>
Signed-off-by: Bo Huang <bo.b.huang@intel.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Because Sprout has removable storage, the framework needs to maintain
external database for keeping multiple databases between SD cards.
When cleaning up databases for old external storage volumes, we can't
delete .db-shm and .db-wal because these two files always have the
latest data and .db doesn't have. Using camera or Google+ will access
.db-shm and .db-wal to get the latest data and will cause SQLite Disk
I/O exception if they are deleted.
The fix is to modify the logic of cleaning up databases (only delete
.db file, not to delete .db-shm and .db-wal file).
Bug 18412563
Review: https://partner-android-review.git.corp.google.com/#/c/187072
Signed-off-by: Benson Huang <benson.huang@mediatek.com>
Change-Id: I484bd535ddebee09824a10f12241f6b2ce086b94
|
|/
|
|
|
|
|
| |
calculated.
Bug: 18118488
Change-Id: If1d12def4598be9cbf86b8550061f4d075be9717
|
|
|
|
|
| |
Bug: 17943556
Change-Id: I1ee026fc0f6248dab2e678e478ba76e8d464dba6
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit c50b2befee37f28f9b482b0a31a62329142e4a6a.
When user set alarm ringtone in DeskClock,
It can't play with AudioManager.STREAM_SYSTEM stream type
Bug: 16906307
Change-Id: Ia0d8df9b5c31441d34dc82678bceccd8ce31423d
|
|
|
|
|
|
| |
Bug 16552638
Change-Id: If32429d6c124970b22075930a60fa23cafed8395
|
|
|
|
|
|
|
|
|
|
| |
When choosing a ringtone, avoid the ringer stream during
playback to avoid interception.
As before, no playback is performed if muted.
Bug:15344396
Change-Id: I7301c7e60682c57187708dfc8fa933a150c5147a
|
|
|
|
|
|
| |
vaguely related to bug 10733373
Change-Id: Icda99a66d893374de7a1ed84d24f2c97a72b90b2
|
|\
| |
| |
| |
| | |
* commit '4c546b546801fc63a7b439ae2350ae4239a664df':
Clean up cursors in try/finally
|
| |
| |
| |
| |
| |
| | |
Make sure we release cursor resources.
Change-Id: Ia122100b1350ae5db4804f8f0e95c49785ab645b
|
|\|
| |
| |
| |
| | |
* commit '98109a4bea074d49106545a349c1b8a401e6635b':
Track API package change.
|
| |\ |
|
| | |
| | |
| | |
| | | |
Change-Id: Ie2ee436d9d5aa8f189bcb5a64116d09fccc5233b
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | | |
needed."
* commit '26fdc564d60a1e2ad73c9a0d63418dc13097e750':
Deactivate the MiniThumbFile when it is not needed.
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Issue description:
Unable to use camera after deleting all files in internal storage from PC
with MTP. The toast message "Connect USB storage before using the camera"
is poped up when we launch camera after deleting all files in internal storage
from PC with MTP.
Steps to reproduce the issue:
1. Launch Camera and take a picture.
2. Connect device to PC with MTP mode.
3. Delete all files on Internal stoage from PC.
4. Launch Camera after step 3 finished.
Then we find that we are unable to use camera and the toast message is poped
up.
Root cause:
The .thumbdata3--xxxxx in /sdcard/DCIM/.thumbnails/ is opened in
android.process.media process when we take picture in step 1. But the file is
never closed. So camera cannot create the directories(/sdcard/DCIM/Camera)
it needs to store captured pictures because "Device busy" error.
Solution:
Deactivate the MiniThumbFile when it is not needed.
Change-Id: I0faab5ffd95c5626f7f9ef1bc02b2ae56e2eb19b
Signed-off-by: hanpengx <pengfeix.han@intel.com>
|
| |
| |
| |
| |
| |
| |
| | |
This fixes a broadcastreceiver leak.
b/13622801
Change-Id: If9da147163c8f819eae66f97424a37e6f6f6d3aa
|