summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGrace Kloba <klobag@google.com>2009-07-06 23:59:10 -0700
committerThe Android Open Source Project <initial-contribution@android.com>2009-07-06 23:59:10 -0700
commit4e48b773e59c23311633b641def8f0f16f951de8 (patch)
tree95d5ab74c1c000251b36262644d4fd4013d833c3
parent4eb3ce6a411b83706d9ffd8af76351249672ed56 (diff)
parentb116c1a08412db8a748998c7e8a2ce851cbacacd (diff)
downloadexternal_webkit-4e48b773e59c23311633b641def8f0f16f951de8.zip
external_webkit-4e48b773e59c23311633b641def8f0f16f951de8.tar.gz
external_webkit-4e48b773e59c23311633b641def8f0f16f951de8.tar.bz2
am b116c1a0: Make deep copy of the String when use them in the UI thread as AtomicString is not thread safe.
Merge commit 'b116c1a08412db8a748998c7e8a2ce851cbacacd' * commit 'b116c1a08412db8a748998c7e8a2ce851cbacacd': Make deep copy of the String when use them in the UI thread as AtomicString is not thread safe.
-rw-r--r--WebKit/android/nav/CacheBuilder.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/WebKit/android/nav/CacheBuilder.cpp b/WebKit/android/nav/CacheBuilder.cpp
index 207de0c..56cb2ae 100644
--- a/WebKit/android/nav/CacheBuilder.cpp
+++ b/WebKit/android/nav/CacheBuilder.cpp
@@ -1103,7 +1103,7 @@ void CacheBuilder::BuildFrame(Frame* root, Frame* frame,
wantsKeyEvents = true;
isPassword = input->inputType() == HTMLInputElement::PASSWORD;
maxLength = input->maxLength();
- name = String(input->name().string());
+ name = input->name().string().copy();
isUnclipped = isTransparent; // can't detect if this is drawn on top (example: deviant.com login parts)
} else if (node->hasTagName(HTMLNames::textareaTag))
isTextArea = wantsKeyEvents = true;
@@ -1126,7 +1126,7 @@ void CacheBuilder::BuildFrame(Frame* root, Frame* frame,
static_cast<RenderTextControl*>(nodeRenderer);
if (isFocus)
cachedRoot->setSelection(renderText->selectionStart(), renderText->selectionEnd());
- exported = String(renderText->text());
+ exported = renderText->text().copy();
// FIXME: Would it be better to use (float) size()?
// FIXME: Are we sure there will always be a style and font, and it's correct?
RenderStyle* style = nodeRenderer->style();