Upstream version 7.36.149.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / modules / encoding / TextDecoder.cpp
index 541540e..84df22c 100644 (file)
 
 namespace WebCore {
 
-PassRefPtrWillBeRawPtr<TextDecoder> TextDecoder::create(const String& label, const Dictionary& options, ExceptionState& exceptionState)
+TextDecoder* TextDecoder::create(const String& label, const Dictionary& options, ExceptionState& exceptionState)
 {
     const String& encodingLabel = label.isNull() ? String("utf-8") : label;
 
     WTF::TextEncoding encoding(encodingLabel);
     if (!encoding.isValid()) {
         exceptionState.throwTypeError("The encoding label provided ('" + encodingLabel + "') is invalid.");
-        return nullptr;
+        return 0;
     }
 
     bool fatal = false;
     options.get("fatal", fatal);
 
-    return adoptRefWillBeNoop(new TextDecoder(encoding.name(), fatal));
+    return new TextDecoder(encoding.name(), fatal);
 }