Closed Bug 274218 Opened 20 years ago Closed 18 years ago

nsIStreamListener documentation unclear about offset parameter

Categories

(Core :: Networking, enhancement)

enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla1.8.1

People

(Reporter: Biesinger, Assigned: Biesinger)

References

()

Details

(Keywords: fixed1.8.1)

Attachments

(1 file, 1 obsolete file)

58      * @param aOffset current stream position

this does not seem to make it clear what the value should be when a channel impl
creates a new stream for each ODA call - for each such ODA, the offset in the
stream would be 0 (since it's a newly created stream). But data has been
transferred already - isn't this argument supposed to be, basically, "amount of
bytes transferred already"?
> isn't this argument supposed to be, basically, "amount of bytes transferred 
> already"

yes, that is how i have always interpreted the parameter.
Assignee: darin → nobody
QA Contact: benc → networking
Attached patch patch (obsolete) — Splinter Review
comment-change only, so it's safe for the branch
Assignee: nobody → cbiesinger
Status: NEW → ASSIGNED
Attachment #229908 - Flags: superreview?(darin)
Attachment #229908 - Flags: review?(darin)
Attachment #229908 - Flags: approval1.8.1?
Target Milestone: --- → mozilla1.8.1
Comment on attachment 229908 [details] [diff] [review]
patch

Please add a comment about what happens to offset for large files.  I think the answer is that when it hits PR_UINT32_MAX, it stays there and does not roll-over.
Attachment #229908 - Flags: superreview?(darin)
Attachment #229908 - Flags: superreview+
Attachment #229908 - Flags: review?(darin)
Attachment #229908 - Flags: review+
Attachment #229908 - Flags: approval1.8.1?
Attachment #229908 - Flags: approval1.8.1+
Attached patch final patchSplinter Review
yep, that's the behaviour of the input stream pump, at least on trunk.
Attachment #229908 - Attachment is obsolete: true
HEAD:
Checking in nsIStreamListener.idl;
/cvsroot/mozilla/netwerk/base/public/nsIStreamListener.idl,v  <--  nsIStreamListener.idl
new revision: 1.21; previous revision: 1.20
done

MOZILLA_1_8_BRANCH:
Checking in nsIStreamListener.idl;
/cvsroot/mozilla/netwerk/base/public/nsIStreamListener.idl,v  <--  nsIStreamListener.idl
new revision: 1.20.8.1; previous revision: 1.20
done

Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Keywords: fixed1.8.1
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: