Open Bug 992888 Opened 10 years ago Updated 2 years ago

FileHandle: Some methods should throw when the window is closed

Categories

(Core :: DOM: Core & HTML, defect, P2)

defect

Tracking

()

People

(Reporter: janv, Unassigned)

Details

+++ This bug was initially created as a clone of Bug #860731 +++

Copying and pasting review comments that were raised in bug 860731. We decided to fix them separately since they don't directly relate to the WebIDL conversion.

Review of attachment 8391945 [details] [diff] [review] [diff] [review]:
-----------------------------------------------------------------

Looks ok, but:

::: dom/file/LockedFile.cpp
@@ +443,5 @@
>    }
>  
> +  // Do nothing if the window is closed
> +  if (!GetOwner()) {
> +    return nullptr;

I think this should throw, right? Below too.

::: dom/file/LockedFile.h
@@ +235,5 @@
> +      return nullptr;
> +    }
> +
> +    if (!length) {
> +      return nullptr;

Shouldn't this return a request?

@@ +240,5 @@
> +    }
> +
> +    // Do nothing if the window is closed
> +    if (!GetOwner()) {
> +      return nullptr;

Shouldn't this set aRv?
No longer blocks: 888591, 942542, 987509
No longer depends on: 860731, 953425
Keywords: leave-open
What's blocking this work?
Flags: needinfo?(jvarga)
Priority: -- → P3
Flags: needinfo?(jvarga)
Priority: P3 → P2
Component: DOM → DOM: Core & HTML
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.