30313 Commits

Author SHA1 Message Date
Mattias Niklewski
114f98a753 Always return a valid index from Rfc822Tokenizer.findTokenEnd()
If an invalid input string ends with a backslash inside a comment
or quoted string, the returned index would be past the end of the
string. In one case this would lead to a runtime exception being
thrown from MultiAutoCompleteTextView.performValidation.

Change-Id: If629372b429716c25cdc25764f088e95d4812d57
2011-04-04 14:52:35 +02:00
Russell Brenner
c6b22e2727 Updated JBQ's original SurfaceTexture stubs to make webkit MR1 buildable
Change-Id: If1c1610efcc0e0bc6de88c75712baed91624b1a7
2011-03-31 17:40:08 -07:00
Russell Brenner
49b49f8fb6 Added include/private/hwui/DrawGlInfo.h
Change-Id: If50ccabb8761a994fa1f7aef4fbdb668c6160b0c
2011-03-31 13:20:52 -07:00
The Android Open Source Project
ad663d8040 Merge from gingerbread
Change-Id: I31e3da083b642d5c7cf6332095fa228b840ee7bb
2011-03-29 13:54:43 -07:00
Michael I. Gold
c3fba3be74 egl: fixes for object refcounts
eglMakeCurrent() would only deref the previous surfaces if the old and
new contexts were the same.  eglTerminate() should not touch TLS.
eglReleaseThread() needs to unbind the current context.

Change-Id: I7f4c090a287ee1e29e4708ae10679fb9d7d8c8c5
Related-Bug: 2964479
2011-03-29 13:43:54 -07:00
Brad Fitzpatrick
1e7fb7aed7 Merge "Error in compound cache-control header." 2011-03-29 08:55:02 -07:00
Henrik Baard
eb0ced7a09 Error in compound cache-control header.
A cache control header containing both no-cache and max-age attribute does not
behave as expected.

Cache-Control: no-cache, max-age=200000

Will set expired to 20000ms seconds, ignoring the no-cache header. My
interpretation is that the no-cache header should not be ignored in
this case.

Change-Id: Iadd1900e4d2c6c0dacc6bb3e7b944cf78ca9b266
2011-03-29 08:54:09 +02:00
Brad Fitzpatrick
f0dbf00d37 Merge "Handle OutOfMemoryError when decoding images in ThumbnailUtils" 2011-03-28 08:13:08 -07:00
Brad Fitzpatrick
1a5a2379eb Merge "Unregister callback from binder when vibration is removed" 2011-03-28 07:59:08 -07:00
Christer Fletcher
375fb9bfd2 Handle OutOfMemoryError when decoding images in ThumbnailUtils
Added handling of OutOfMemoryError handling to createImageThumbnail
method in ThumbnailUtils.java. During mediascanner run it would run
out of memory when trying to decode very large images. Now it handles
this error and returns null which is handled by the media scanner.

Change-Id: Ie68722dfa1cedd3c0847bf483baa40c4827ad5a8
2011-03-28 14:47:55 +02:00
Mathias Jeppsson
b23949b745 Unregister callback from binder when vibration is removed
When creating new vibration pattern, a callback is registered
in case binding to caller goes away, by linkToDeath().
Need to unregister this callback when we throw away the vibration.

Change-Id: Ibdf0bd415a539054ac7a66f49b33a864f729c546
2011-03-24 08:49:12 +01:00
Brad Fitzpatrick
2e383bc644 Merge "Making it possible to call SIP calls with special allowed chars." 2011-03-23 12:33:39 -07:00
Brad Fitzpatrick
5d5a0ca5eb Merge "Fixing the wrong link in YuvImage JavaDoc." 2011-03-23 12:30:28 -07:00
Magnus Strandberg
b5c72ead01 Making it possible to call SIP calls with special allowed chars.
Since String.replaceFirst uses regex and since SIP user names are
allowed to include regex charaters such as '+', the code must
fist convert the string to a literal pattern String before using
replaceFirst method.

Change-Id: I25eac852bd620724ca1c5b2befc023af9dae3c1a
2011-03-22 08:03:58 +01:00
Brad Fitzpatrick
d973bed36c Merge "Removing dead store; it was likely a relict of debuging code." 2011-03-17 09:51:47 -07:00
Jozef BABJAK
f1aa297b17 Removing dead store; it was likely a relict of debuging code.
Change-Id: I4daab1359d7c4b300ef61e3de1578d9fecb6f8da
2011-03-17 09:23:32 +01:00
Brad Fitzpatrick
8d25eab105 Merge "Releasing lock even if exception is thrown." 2011-03-15 11:23:44 -07:00
Brad Fitzpatrick
56c4c442c0 Merge "Lazy initialization must be synchronized to avoid parallel instances cretation." 2011-03-15 11:22:43 -07:00
Brad Fitzpatrick
b98c8fca95 Merge "Removing self-assignment statement." 2011-03-15 11:19:23 -07:00
Brad Fitzpatrick
8b5345fb36 Merge "Fixing self-assignment in copying code." 2011-03-15 11:18:18 -07:00
Brad Fitzpatrick
9a01a2f272 Merge "Fixing self-assignment in cloning code." 2011-03-15 11:15:19 -07:00
Brad Fitzpatrick
7972e38280 Merge "Removing repetitive conditional; it simply does nothing except slowing down things." 2011-03-15 11:13:01 -07:00
Brad Fitzpatrick
38c6e31c88 Merge "Removing repetitive conditional; it simply does nothing except slowing down things." 2011-03-15 11:12:15 -07:00
Brad Fitzpatrick
29d75c9a10 Merge "Fixing improper boxing to Integer instead of Long." 2011-03-15 11:03:29 -07:00
Brad Fitzpatrick
40b207c131 Merge "Using proper key for removing object from the map." 2011-03-15 11:00:51 -07:00
Brad Fitzpatrick
b37f7e59ee Merge changes I81fc2f90,I5e7fd759
* changes:
  Using proper key for removing from map.
  Removing wrong equals method in comparator.
2011-03-15 10:56:16 -07:00
Kenny Root
2fdf829a17 Merge "Remove unnecessary SkImageDecoder_libjpeg.cpp" 2011-03-11 14:22:22 -08:00
Chih-Wei Huang
c2d68c9096 Remove unnecessary SkImageDecoder_libjpeg.cpp
Adding files outside $(LOCAL_PATH) is a bad idea. It generates output files
to an unexpected directory. In this case, it's

out/target/external/skia/src/images/SkImageDecoder_libjpeg.o

It's not in $(PRODUCT_OUT), which is not correct.
Worse, it makes the build system be unable to build different
architectures (arm and x86) simultaneously, since the output files
conflcit.

Seems we can just remove SkImageDecoder_libjpeg.cpp since it's
already in libskia.

Change-Id: I3e7533126ef60fe2fd424fdc777760e73c93489b
2011-03-10 17:52:31 +08:00
Jozef BABJAK
17eb45fff8 Lazy initialization must be synchronized to avoid parallel instances cretation.
Change-Id: I9c6887c714f42534a465c266689dc03ee7298900
2011-03-03 10:22:12 +01:00
Jozef BABJAK
0dbe721d0a Fixing improper boxing to Integer instead of Long.
This is tricky: entry.getMessageBox() returns int, so it is
by default boxed to Integer. Map.get() however accepts Objects,
so it ignores the difference, but nothing is find during lookup,
just because Long and Integer objects are compared using equals(),
which has to lead to 'false' result. So, explicit boxning to Long
is unnecessary here.

Change-Id: I967a7829a8926410a00274c6b5e312e1af567299
2011-03-03 10:09:53 +01:00
Dianne Hackborn
1de4a2ca58 am 62619392: Merge "Fix leak when keylock is recreated."
* commit '626193926df0b3c7236e5c244f30d797d9192e0d':
  Fix leak when keylock is recreated.
2011-02-28 18:03:12 -08:00
Dianne Hackborn
626193926d Merge "Fix leak when keylock is recreated." 2011-02-28 17:54:54 -08:00
Jaikumar Ganesh
9711b9b7aa am 1eefb529: Merge "Phone crash when old callback func is woken up when enabling BT."
* commit '1eefb529c78be5336f6c8a1b8ac2c32e268d4294':
  Phone crash when old callback func is woken up when enabling BT.
2011-02-28 16:00:01 -08:00
Jaikumar Ganesh
1eefb529c7 Merge "Phone crash when old callback func is woken up when enabling BT." 2011-02-28 15:33:34 -08:00
Jean-Baptiste Queru
25be2c725e am e0537f18: Merge "Fix of tearDown() in SingleLaunchActivityTestCase."
* commit 'e0537f1859664ba9c9cf87eb9d6dc3c16986dbb8':
  Fix of tearDown() in SingleLaunchActivityTestCase.
2011-02-28 10:15:46 -08:00
Jean-Baptiste Queru
e0537f1859 Merge "Fix of tearDown() in SingleLaunchActivityTestCase." 2011-02-28 10:12:08 -08:00
Xavier Ducrohet
6504490cde am dff6b8e7: Merge "Add --non-constant-id to aapt."
* commit 'dff6b8e71dda9f5d841fa26408714aec2aef1505':
  GpsLocationProvider: Clean up HAL initialization/cleanup sequence
  Fixed GSM encoded network initiated position request
  Ensuring thread-safe usage of DateFormat.
  Fixing infinite loop for zero duration.
  Fix for an infinite loop while scrolling lists.
  WAPPushManager, WAP Push over SMS message handler
  Add --non-constant-id to aapt.
2011-02-28 09:16:38 -08:00
Kenneth Andersson
1e0c7ae184 Fix leak when keylock is recreated.
DigitalClock could sometimes leak when the keylock was recreated.
This happened because onDetachedFromWindow() was called BEFORE
onAttachedFromWindow().
This is the flow that causes the memory leak:
1) The LockPatternKeyGuardView is created and added. This will start
a loop dispatching onAttachedToWindow() to all views involved.
2) PatternUnlockScreen.onAttachedToWindow() is called
3) If the configuration has changed since creation, recreateMe() in
LockPatternKeyguardView.java is called.
4) recreateScreens() is called
5) PatternUnlockScreen is removed (to be re-added later) in
LockPatternKeyguardView.recreateUnlockScreen()
6) Since DigitalClock is a part of PatternUnlockScreen, its
onDetachedFromWindow() will be called.
7) The loop started in 1) will continue to dispatch
onAttachedToWindow() - and will eventually call
DigitalClock.onAttachedToWindow()
8) DigitalClock.onAttachedToWindow() registers a receiver that is
normally unregistered in onDetachedFromWindow(). But since
onDetachedFromWindow was already called in 6), it will not be called
again.
9) The receiver has leaked, and it has a reference to DigitalClock,
so that will leak as well, together with its parents e.g.
PatternUnlockScreen and LockPatternKeyguardView

The fix is to wait with the recreation of the screens (in 4) until
the loop (in 1) is finished. This is done by posting this as an event
instead of calling recreateScreens() immediately.

It is possible that this a fix for the root cause mentioned in
"Fix 3106227: use WeakReferences for receivers in DigitalClock class"
8b886fab5496b0b1f5193f21855220176deddc37 by Jim Miller
<jaggies@google.com>.

Change-Id: I6a5f6f49a565d459bf4e285f34f053cc1022286f
2011-02-28 14:09:08 +01:00
Xavier Ducrohet
dff6b8e71d Merge "Add --non-constant-id to aapt." 2011-02-24 15:59:26 -08:00
Wink Saville
bf87c11590 Merge "WAPPushManager, WAP Push over SMS message handler" 2011-02-23 17:40:43 -08:00
Mike Lockwood
e2567f2200 Merge "GpsLocationProvider: Clean up HAL initialization/cleanup sequence" 2011-02-23 16:27:27 -08:00
Mike Lockwood
0a5098106c GpsLocationProvider: Clean up HAL initialization/cleanup sequence
Change-Id: Id5467000f3f3da5cbe1f112dad97a032688d2eac
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-23 14:01:44 -08:00
Brad Fitzpatrick
0ca6bf18af Merge "Fixed GSM encoded network initiated position request" 2011-02-23 08:17:31 -08:00
Elliott Hughes
904f8a2032 Merge "Ensuring thread-safe usage of DateFormat." 2011-02-22 11:16:04 -08:00
Brad Fitzpatrick
a67191a174 Merge "Fix for an infinite loop while scrolling lists." 2011-02-22 10:55:44 -08:00
Brad Fitzpatrick
4564e9c34f Merge "Fixing infinite loop for zero duration." 2011-02-22 08:23:23 -08:00
Hakan Gustavsson
6664d989c8 Fixed GSM encoded network initiated position request
GSM encoded network initiated position requests were previously
not correctly decoded. The GSM encoded string was decoded as
ASCII but not all characters are encoded in the same way for
GSM and ASCII. These characters was not displayed.

Besides that, when the number of characters was evenly divided
by 8 the last character was lost. This is also corrected.

Change-Id: Ic70b7c28bbba1f2936a9cc99e78f8002cc5c8761
2011-02-22 14:35:47 +01:00
Jozef BABJAK
93c5b6a81d Releasing lock even if exception is thrown.
However, the whole method needs to be reviewed. It still has several
locking/unlocking places not tied together by try-finally construct,
but they cannot be fixed without deeper understanding.

Change-Id: Iaaf87568d585327654be409377b6d57a1da135eb
2011-02-22 09:33:19 +01:00
Jozef BABJAK
25d8b05fb7 Ensuring thread-safe usage of DateFormat.
DateFormat is inherently unsafe for multithreaded use. This patch adds
proper synchronization. The 'sLock' is re-used. To avoid two consecutive
lockings, locked version of initFormatStrings() method is created and
used where appropriate, i.e. in original method AND in added synchronized
block.

Change-Id: Id3c34613623e743e703aadb2342aa788679dda8a
2011-02-22 09:17:51 +01:00
Jozef BABJAK
c007925423 Removing self-assignment statement.
Change-Id: I429235093de4539bde3950075fbdaa4ef5bdeedd
2011-02-22 08:09:01 +01:00