Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(888)

Issue 490033005: Fallback to unsupported browser type instead of returning null (Closed)

Created:
6 years, 3 months ago by vsm
Modified:
6 years, 3 months ago
Reviewers:
Leaf, siva
CC:
reviews+dom_dartlang.org
Visibility:
Public.

Description

Fallback to unsupported browser type instead of returning null Corresponds to: https://chromiumcodereview.appspot.com/483263004/ BUG=dartbug.com/20592 R=leafp@google.com Committed: https://src.chromium.org/viewvc/blink/branches/dart/dartium?view=rev&revision=180943

Patch Set 1 #

Total comments: 4

Patch Set 2 : Address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+10 lines, -2 lines) Patch
M Source/bindings/dart/DartDOMWrapper.cpp View 1 1 chunk +10 lines, -2 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
vsm
vsm@google.com changed reviewers: + asiva@google.com, leafp@google.com
6 years, 3 months ago (2014-08-26 14:52:23 UTC) #1
vsm
6 years, 3 months ago (2014-08-26 14:52:28 UTC) #2
Leaf
lgtm
6 years, 3 months ago (2014-08-26 17:49:20 UTC) #3
siva
https://chromiumcodereview.appspot.com/490033005/diff/1/Source/bindings/dart/DartDOMWrapper.cpp File Source/bindings/dart/DartDOMWrapper.cpp (right): https://chromiumcodereview.appspot.com/490033005/diff/1/Source/bindings/dart/DartDOMWrapper.cpp#newcode79 Source/bindings/dart/DartDOMWrapper.cpp:79: strncat(message, DartWebkitClassInfo[cid].jsName, 255 - strlen(message)); Why not use snprint(message, ...
6 years, 3 months ago (2014-08-26 19:31:14 UTC) #4
vsm
Committed patchset #2 manually as 180943 (presubmit successful).
6 years, 3 months ago (2014-08-27 07:48:27 UTC) #5
vsm
https://chromiumcodereview.appspot.com/490033005/diff/1/Source/bindings/dart/DartDOMWrapper.cpp File Source/bindings/dart/DartDOMWrapper.cpp (right): https://chromiumcodereview.appspot.com/490033005/diff/1/Source/bindings/dart/DartDOMWrapper.cpp#newcode79 Source/bindings/dart/DartDOMWrapper.cpp:79: strncat(message, DartWebkitClassInfo[cid].jsName, 255 - strlen(message)); On 2014/08/26 19:31:14, siva ...
6 years, 3 months ago (2014-08-27 07:50:29 UTC) #6
vsm
6 years, 3 months ago (2014-08-27 08:05:11 UTC) #7
Message was sent while issue was closed.
https://chromiumcodereview.appspot.com/490033005/diff/1/Source/bindings/dart/...
File Source/bindings/dart/DartDOMWrapper.cpp (right):

https://chromiumcodereview.appspot.com/490033005/diff/1/Source/bindings/dart/...
Source/bindings/dart/DartDOMWrapper.cpp:82: type = Dart_GetType(htmlLibrary,
Dart_NewStringFromCString("_UnsupportedBrowserObject"), 0, 0);
As long as we continue to push the types to user code, we do need something
defensive here.  We cannot assume we'll get a type or a valid type.

Should we also verify that this type has (at least) two native fields?  What
happens if we call Dart_AllocateWithNativeFields on some arbitrary type?

On 2014/08/26 19:31:14, siva wrote:
> I hope this is just a temporary solution, when we start generating
> code using the actual chrome IDL instead of the way things are being
> done now this should never happen right. Any error here would be more
> an InternalError.

Powered by Google App Engine
This is Rietveld 408576698