diff --git a/netwerk/base/public/nsIUploadChannel2.idl b/netwerk/base/public/nsIUploadChannel2.idl index 33af467711af..3fae81c36e55 100644 --- a/netwerk/base/public/nsIUploadChannel2.idl +++ b/netwerk/base/public/nsIUploadChannel2.idl @@ -39,7 +39,7 @@ interface nsIInputStream; -[scriptable, uuid(8821E259-7252-4464-B874-A55D8EF6B222)] +[scriptable, uuid(AD9D3F1C-A8DE-4d0b-9714-1B922297AD65)] interface nsIUploadChannel2 : nsISupports { /** @@ -70,4 +70,9 @@ interface nsIUploadChannel2 : nsISupports in long long aContentLength, in ACString aMethod, in boolean aStreamHasHeaders); + + /** + * + */ + readonly attribute boolean uploadStreamHasHeaders; }; diff --git a/netwerk/protocol/http/HttpBaseChannel.cpp b/netwerk/protocol/http/HttpBaseChannel.cpp index d6802e5fc059..aaefffd082c1 100644 --- a/netwerk/protocol/http/HttpBaseChannel.cpp +++ b/netwerk/protocol/http/HttpBaseChannel.cpp @@ -498,6 +498,15 @@ HttpBaseChannel::ExplicitSetUploadStream(nsIInputStream *aStream, return NS_OK; } +NS_IMETHODIMP +HttpBaseChannel::GetUploadStreamHasHeaders(PRBool *hasHeaders) +{ + NS_ENSURE_ARG(hasHeaders); + + *hasHeaders = mUploadStreamHasHeaders; + return NS_OK; +} + //----------------------------------------------------------------------------- // HttpBaseChannel::nsIEncodedChannel //-----------------------------------------------------------------------------