зеркало из https://github.com/mozilla/gecko-dev.git
Bug 646071 - Part 3: Remove nsInt64.h, and convert all uses of nsInt64 and nsUint64 in the tree to PRInt64 and PRUint64, respectively; r=bsmedberg
This commit is contained in:
Родитель
18b3ad188c
Коммит
bd51cb9b94
|
@ -60,7 +60,6 @@
|
|||
#include "nsCRT.h"
|
||||
#include "prtime.h"
|
||||
#include "prlog.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsNodeUtils.h"
|
||||
#include "nsIContent.h"
|
||||
#include "mozilla/dom/Element.h"
|
||||
|
|
|
@ -62,7 +62,6 @@
|
|||
#include "nsIStringEnumerator.h"
|
||||
#include "nsCRT.h"
|
||||
#include "nsSupportsArray.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsContentCID.h"
|
||||
#include "nsStreamUtils.h"
|
||||
|
||||
|
@ -168,8 +167,8 @@ struct OutputData
|
|||
nsCOMPtr<nsIURI> mFile;
|
||||
nsCOMPtr<nsIURI> mOriginalLocation;
|
||||
nsCOMPtr<nsIOutputStream> mStream;
|
||||
nsInt64 mSelfProgress;
|
||||
nsInt64 mSelfProgressMax;
|
||||
PRInt64 mSelfProgress;
|
||||
PRInt64 mSelfProgressMax;
|
||||
PRPackedBool mCalcFileExt;
|
||||
|
||||
OutputData(nsIURI *aFile, nsIURI *aOriginalLocation, PRBool aCalcFileExt) :
|
||||
|
@ -192,8 +191,8 @@ struct OutputData
|
|||
struct UploadData
|
||||
{
|
||||
nsCOMPtr<nsIURI> mFile;
|
||||
nsInt64 mSelfProgress;
|
||||
nsInt64 mSelfProgressMax;
|
||||
PRInt64 mSelfProgress;
|
||||
PRInt64 mSelfProgressMax;
|
||||
|
||||
UploadData(nsIURI *aFile) :
|
||||
mFile(aFile),
|
||||
|
@ -244,6 +243,8 @@ nsWebBrowserPersist::nsWebBrowserPersist() :
|
|||
mPersistFlags(kDefaultPersistFlags),
|
||||
mPersistResult(NS_OK),
|
||||
mWrapColumn(72),
|
||||
mTotalCurrentProgress(0),
|
||||
mTotalMaxProgress(0),
|
||||
mEncodingFlags(0)
|
||||
{
|
||||
}
|
||||
|
|
|
@ -58,7 +58,6 @@
|
|||
|
||||
#include "nsHashtable.h"
|
||||
#include "nsTArray.h"
|
||||
#include "nsInt64.h"
|
||||
|
||||
#include "nsCWebBrowserPersist.h"
|
||||
|
||||
|
@ -240,8 +239,8 @@ private:
|
|||
PRPackedBool mSerializingOutput;
|
||||
PRUint32 mPersistFlags;
|
||||
PRUint32 mPersistResult;
|
||||
nsInt64 mTotalCurrentProgress;
|
||||
nsInt64 mTotalMaxProgress;
|
||||
PRInt64 mTotalCurrentProgress;
|
||||
PRInt64 mTotalMaxProgress;
|
||||
PRInt16 mWrapColumn;
|
||||
PRUint32 mEncodingFlags;
|
||||
nsString mContentType;
|
||||
|
|
|
@ -42,7 +42,6 @@
|
|||
#include "nsJARProtocolHandler.h"
|
||||
#include "nsMimeTypes.h"
|
||||
#include "nsNetUtil.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsEscape.h"
|
||||
#include "nsIPrefService.h"
|
||||
#include "nsIPrefBranch.h"
|
||||
|
|
|
@ -56,7 +56,6 @@
|
|||
#include "plstr.h"
|
||||
#include "nsILocalFileMac.h"
|
||||
#include "nsIFileURL.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsTArray.h"
|
||||
#include "nsObjCExceptions.h"
|
||||
|
||||
|
@ -220,7 +219,7 @@ NS_IMETHODIMP nsIconChannel::AsyncOpen(nsIStreamListener *aListener, nsISupports
|
|||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
// Init our stream pump
|
||||
rv = mPump->Init(inStream, nsInt64(-1), nsInt64(-1), 0, 0, PR_FALSE);
|
||||
rv = mPump->Init(inStream, PRInt64(-1), PRInt64(-1), 0, 0, PR_FALSE);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
rv = mPump->AsyncRead(this, ctxt);
|
||||
|
|
|
@ -47,7 +47,6 @@
|
|||
#include "nsReadableUtils.h"
|
||||
#include "nsMemory.h"
|
||||
#include "nsNetUtil.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsILocalFile.h"
|
||||
#include "nsIFileURL.h"
|
||||
#include "nsDirectoryServiceDefs.h"
|
||||
|
@ -203,7 +202,7 @@ NS_IMETHODIMP nsIconChannel::AsyncOpen(nsIStreamListener *aListener, nsISupports
|
|||
return rv;
|
||||
|
||||
// Init our streampump
|
||||
rv = mPump->Init(inStream, nsInt64(-1), nsInt64(-1), 0, 0, PR_FALSE);
|
||||
rv = mPump->Init(inStream, PRInt64(-1), PRInt64(-1), 0, 0, PR_FALSE);
|
||||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
|
|
|
@ -53,7 +53,6 @@
|
|||
#include "nsIStringStream.h"
|
||||
#include "nsIURL.h"
|
||||
#include "nsNetUtil.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsIFile.h"
|
||||
#include "nsIFileURL.h"
|
||||
#include "nsIMIMEService.h"
|
||||
|
@ -249,7 +248,7 @@ NS_IMETHODIMP nsIconChannel::AsyncOpen(nsIStreamListener *aListener, nsISupports
|
|||
return rv;
|
||||
|
||||
// Init our streampump
|
||||
rv = mPump->Init(inStream, nsInt64(-1), nsInt64(-1), 0, 0, PR_FALSE);
|
||||
rv = mPump->Init(inStream, PRInt64(-1), PRInt64(-1), 0, 0, PR_FALSE);
|
||||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
|
|
|
@ -133,7 +133,6 @@
|
|||
#include "nsAppDirectoryServiceDefs.h"
|
||||
#include "nsIFile.h"
|
||||
#include "nsPluginDirServiceProvider.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsPluginError.h"
|
||||
|
||||
#include "nsUnicharUtils.h"
|
||||
|
@ -2949,7 +2948,7 @@ nsPluginHost::ReadPluginInfo()
|
|||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
PRInt32 flen = nsInt64(fileSize);
|
||||
PRInt32 flen = PRInt64(fileSize);
|
||||
if (flen == 0) {
|
||||
NS_WARNING("Plugins Registry Empty!");
|
||||
return NS_OK; // ERROR CONDITION
|
||||
|
|
|
@ -969,7 +969,7 @@ NS_IMETHODIMP nsPluginStreamListenerPeer::OnDataAvailable(nsIRequest *request,
|
|||
brr->GetStartRange(&absoluteOffset64);
|
||||
|
||||
// XXX handle 64-bit for real
|
||||
PRInt32 absoluteOffset = (PRInt32)nsInt64(absoluteOffset64);
|
||||
PRInt32 absoluteOffset = (PRInt32)PRInt64(absoluteOffset64);
|
||||
|
||||
// we need to track how much data we have forwarded to the
|
||||
// plugin.
|
||||
|
@ -1049,7 +1049,7 @@ NS_IMETHODIMP nsPluginStreamListenerPeer::OnStopRequest(nsIRequest *request,
|
|||
PRInt64 absoluteOffset64 = LL_ZERO;
|
||||
brr->GetStartRange(&absoluteOffset64);
|
||||
// XXX support 64-bit offsets
|
||||
PRInt32 absoluteOffset = (PRInt32)nsInt64(absoluteOffset64);
|
||||
PRInt32 absoluteOffset = (PRInt32)PRInt64(absoluteOffset64);
|
||||
|
||||
nsPRUintKey key(absoluteOffset);
|
||||
|
||||
|
|
|
@ -90,7 +90,6 @@
|
|||
#include "nsIPersistentProperties2.h"
|
||||
#include "nsISyncStreamListener.h"
|
||||
#include "nsInterfaceRequestorAgg.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsINetUtil.h"
|
||||
#include "nsIURIWithPrincipal.h"
|
||||
#include "nsIAuthPrompt.h"
|
||||
|
@ -490,8 +489,8 @@ NS_NewInputStreamChannel(nsIChannel **result,
|
|||
inline nsresult
|
||||
NS_NewInputStreamPump(nsIInputStreamPump **result,
|
||||
nsIInputStream *stream,
|
||||
PRInt64 streamPos = nsInt64(-1),
|
||||
PRInt64 streamLen = nsInt64(-1),
|
||||
PRInt64 streamPos = PRInt64(-1),
|
||||
PRInt64 streamLen = PRInt64(-1),
|
||||
PRUint32 segsize = 0,
|
||||
PRUint32 segcount = 0,
|
||||
PRBool closeWhenDone = PR_FALSE)
|
||||
|
@ -1040,7 +1039,7 @@ NS_BackgroundInputStream(nsIInputStream **result,
|
|||
do_GetService(NS_STREAMTRANSPORTSERVICE_CONTRACTID, &rv);
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
nsCOMPtr<nsITransport> inTransport;
|
||||
rv = sts->CreateInputTransport(stream, nsInt64(-1), nsInt64(-1),
|
||||
rv = sts->CreateInputTransport(stream, PRInt64(-1), PRInt64(-1),
|
||||
PR_TRUE, getter_AddRefs(inTransport));
|
||||
if (NS_SUCCEEDED(rv))
|
||||
rv = inTransport->OpenInputStream(nsITransport::OPEN_BLOCKING,
|
||||
|
@ -1064,7 +1063,7 @@ NS_BackgroundOutputStream(nsIOutputStream **result,
|
|||
do_GetService(NS_STREAMTRANSPORTSERVICE_CONTRACTID, &rv);
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
nsCOMPtr<nsITransport> inTransport;
|
||||
rv = sts->CreateOutputTransport(stream, nsInt64(-1), nsInt64(-1),
|
||||
rv = sts->CreateOutputTransport(stream, PRInt64(-1), PRInt64(-1),
|
||||
PR_TRUE, getter_AddRefs(inTransport));
|
||||
if (NS_SUCCEEDED(rv))
|
||||
rv = inTransport->OpenOutputStream(nsITransport::OPEN_BLOCKING,
|
||||
|
|
|
@ -165,7 +165,7 @@ nsBufferedStream::Seek(PRInt32 whence, PRInt64 offset)
|
|||
nsCOMPtr<nsISeekableStream> ras = do_QueryInterface(mStream, &rv);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
nsInt64 absPos;
|
||||
PRInt64 absPos = 0;
|
||||
switch (whence) {
|
||||
case nsISeekableStream::NS_SEEK_SET:
|
||||
absPos = offset;
|
||||
|
@ -205,8 +205,8 @@ nsBufferedStream::Seek(PRInt32 whence, PRInt64 offset)
|
|||
|
||||
METER(if (bufstats.mBigSeekIndex < MAX_BIG_SEEKS)
|
||||
bufstats.mBigSeek[bufstats.mBigSeekIndex].mOldOffset =
|
||||
mBufferStartOffset + nsInt64(mCursor));
|
||||
const nsInt64 minus1 = -1;
|
||||
mBufferStartOffset + PRInt64(mCursor));
|
||||
const PRInt64 minus1 = -1;
|
||||
if (absPos == minus1) {
|
||||
// then we had the SEEK_END case, above
|
||||
PRInt64 tellPos;
|
||||
|
@ -231,7 +231,7 @@ nsBufferedStream::Tell(PRInt64 *result)
|
|||
if (mStream == nsnull)
|
||||
return NS_BASE_STREAM_CLOSED;
|
||||
|
||||
nsInt64 result64 = mBufferStartOffset;
|
||||
PRInt64 result64 = mBufferStartOffset;
|
||||
result64 += mCursor;
|
||||
*result = result64;
|
||||
return NS_OK;
|
||||
|
|
|
@ -45,7 +45,6 @@
|
|||
#include "nsISeekableStream.h"
|
||||
#include "nsIStreamBufferAccess.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsIIPCSerializable.h"
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -70,7 +69,7 @@ protected:
|
|||
char* mBuffer;
|
||||
|
||||
// mBufferStartOffset is the offset relative to the start of mStream.
|
||||
nsInt64 mBufferStartOffset;
|
||||
PRInt64 mBufferStartOffset;
|
||||
|
||||
// mCursor is the read cursor for input streams, or write cursor for
|
||||
// output streams, and is relative to mBufferStartOffset.
|
||||
|
|
|
@ -57,7 +57,6 @@
|
|||
#include "nsXPIDLString.h"
|
||||
#include "prerror.h"
|
||||
#include "nsCRT.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsIFile.h"
|
||||
#include "nsDirectoryIndexStream.h"
|
||||
#include "nsMimeTypes.h"
|
||||
|
@ -107,8 +106,8 @@ nsFileStream::Seek(PRInt32 whence, PRInt64 offset)
|
|||
if (mFD == nsnull)
|
||||
return NS_BASE_STREAM_CLOSED;
|
||||
|
||||
nsInt64 cnt = PR_Seek64(mFD, offset, (PRSeekWhence)whence);
|
||||
if (cnt == nsInt64(-1)) {
|
||||
PRInt64 cnt = PR_Seek64(mFD, offset, (PRSeekWhence)whence);
|
||||
if (cnt == PRInt64(-1)) {
|
||||
return NS_ErrorAccordingToNSPR();
|
||||
}
|
||||
return NS_OK;
|
||||
|
@ -123,8 +122,8 @@ nsFileStream::Tell(PRInt64 *result)
|
|||
if (mFD == nsnull)
|
||||
return NS_BASE_STREAM_CLOSED;
|
||||
|
||||
nsInt64 cnt = PR_Seek64(mFD, 0, PR_SEEK_CUR);
|
||||
if (cnt == nsInt64(-1)) {
|
||||
PRInt64 cnt = PR_Seek64(mFD, 0, PR_SEEK_CUR);
|
||||
if (cnt == PRInt64(-1)) {
|
||||
return NS_ErrorAccordingToNSPR();
|
||||
}
|
||||
*result = cnt;
|
||||
|
|
|
@ -48,7 +48,6 @@
|
|||
#include "nsIServiceManager.h"
|
||||
#include "nsILocalFile.h"
|
||||
#include "nsITimer.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsNetUtil.h"
|
||||
#include "nsAutoPtr.h"
|
||||
#include "nsWeakReference.h"
|
||||
|
@ -101,7 +100,7 @@ AppendToFile(nsILocalFile *lf, const char *data, PRUint32 len)
|
|||
|
||||
// maxSize may be -1 if unknown
|
||||
static void
|
||||
MakeRangeSpec(const nsInt64 &size, const nsInt64 &maxSize, PRInt32 chunkSize,
|
||||
MakeRangeSpec(const PRInt64 &size, const PRInt64 &maxSize, PRInt32 chunkSize,
|
||||
PRBool fetchRemaining, nsCString &rangeSpec)
|
||||
{
|
||||
rangeSpec.AssignLiteral("bytes=");
|
||||
|
@ -111,8 +110,8 @@ MakeRangeSpec(const nsInt64 &size, const nsInt64 &maxSize, PRInt32 chunkSize,
|
|||
if (fetchRemaining)
|
||||
return;
|
||||
|
||||
nsInt64 end = size + nsInt64(chunkSize);
|
||||
if (maxSize != nsInt64(-1) && end > maxSize)
|
||||
PRInt64 end = size + PRInt64(chunkSize);
|
||||
if (maxSize != PRInt64(-1) && end > maxSize)
|
||||
end = maxSize;
|
||||
end -= 1;
|
||||
|
||||
|
@ -165,8 +164,8 @@ private:
|
|||
PRInt32 mChunkLen;
|
||||
PRInt32 mChunkSize;
|
||||
PRInt32 mInterval;
|
||||
nsInt64 mTotalSize;
|
||||
nsInt64 mCurrentSize;
|
||||
PRInt64 mTotalSize;
|
||||
PRInt64 mCurrentSize;
|
||||
PRUint32 mLoadFlags;
|
||||
PRInt32 mNonPartialCount;
|
||||
nsresult mStatus;
|
||||
|
@ -197,7 +196,7 @@ nsIncrementalDownload::nsIncrementalDownload()
|
|||
nsresult
|
||||
nsIncrementalDownload::FlushChunk()
|
||||
{
|
||||
NS_ASSERTION(mTotalSize != nsInt64(-1), "total size should be known");
|
||||
NS_ASSERTION(mTotalSize != PRInt64(-1), "total size should be known");
|
||||
|
||||
if (mChunkLen == 0)
|
||||
return NS_OK;
|
||||
|
@ -206,7 +205,7 @@ nsIncrementalDownload::FlushChunk()
|
|||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
mCurrentSize += nsInt64(mChunkLen);
|
||||
mCurrentSize += PRInt64(mChunkLen);
|
||||
mChunkLen = 0;
|
||||
|
||||
return NS_OK;
|
||||
|
@ -285,7 +284,7 @@ nsIncrementalDownload::ProcessTimeout()
|
|||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
NS_ASSERTION(mCurrentSize != nsInt64(-1),
|
||||
NS_ASSERTION(mCurrentSize != PRInt64(-1),
|
||||
"we should know the current file size by now");
|
||||
|
||||
rv = ClearRequestHeader(http);
|
||||
|
@ -294,7 +293,7 @@ nsIncrementalDownload::ProcessTimeout()
|
|||
|
||||
// Don't bother making a range request if we are just going to fetch the
|
||||
// entire document.
|
||||
if (mInterval || mCurrentSize != nsInt64(0)) {
|
||||
if (mInterval || mCurrentSize != PRInt64(0)) {
|
||||
nsCAutoString range;
|
||||
MakeRangeSpec(mCurrentSize, mTotalSize, mChunkSize, mInterval == 0, range);
|
||||
|
||||
|
@ -319,7 +318,7 @@ nsIncrementalDownload::ProcessTimeout()
|
|||
nsresult
|
||||
nsIncrementalDownload::ReadCurrentSize()
|
||||
{
|
||||
nsInt64 size;
|
||||
PRInt64 size;
|
||||
nsresult rv = mDest->GetFileSize((PRInt64 *) &size);
|
||||
if (rv == NS_ERROR_FILE_NOT_FOUND ||
|
||||
rv == NS_ERROR_FILE_TARGET_DOES_NOT_EXIST) {
|
||||
|
@ -553,7 +552,7 @@ nsIncrementalDownload::OnStartRequest(nsIRequest *request,
|
|||
// We may already have the entire file downloaded, in which case
|
||||
// our request for a range beyond the end of the file would have
|
||||
// been met with an error response code.
|
||||
if (code == 416 && mTotalSize == nsInt64(-1)) {
|
||||
if (code == 416 && mTotalSize == PRInt64(-1)) {
|
||||
mTotalSize = mCurrentSize;
|
||||
// Return an error code here to suppress OnDataAvailable.
|
||||
return NS_ERROR_DOWNLOAD_COMPLETE;
|
||||
|
@ -587,7 +586,7 @@ nsIncrementalDownload::OnStartRequest(nsIRequest *request,
|
|||
}
|
||||
|
||||
// Do special processing after the first response.
|
||||
if (mTotalSize == nsInt64(-1)) {
|
||||
if (mTotalSize == PRInt64(-1)) {
|
||||
// Update knowledge of mFinalURI
|
||||
rv = http->GetURI(getter_AddRefs(mFinalURI));
|
||||
if (NS_FAILED(rv))
|
||||
|
@ -616,7 +615,7 @@ nsIncrementalDownload::OnStartRequest(nsIRequest *request,
|
|||
rv = props->GetPropertyAsInt64(NS_CHANNEL_PROP_CONTENT_LENGTH,
|
||||
&mTotalSize);
|
||||
// We need to know the total size of the thing we're trying to download.
|
||||
if (mTotalSize == nsInt64(-1)) {
|
||||
if (mTotalSize == PRInt64(-1)) {
|
||||
NS_WARNING("server returned no content-length header!");
|
||||
return NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
|
@ -633,13 +632,13 @@ nsIncrementalDownload::OnStartRequest(nsIRequest *request,
|
|||
}
|
||||
|
||||
// Adjust mChunkSize accordingly if mCurrentSize is close to mTotalSize.
|
||||
nsInt64 diff = mTotalSize - mCurrentSize;
|
||||
if (diff <= nsInt64(0)) {
|
||||
PRInt64 diff = mTotalSize - mCurrentSize;
|
||||
if (diff <= PRInt64(0)) {
|
||||
NS_WARNING("about to set a bogus chunk size; giving up");
|
||||
return NS_ERROR_UNEXPECTED;
|
||||
}
|
||||
|
||||
if (diff < nsInt64(mChunkSize))
|
||||
if (diff < PRInt64(mChunkSize))
|
||||
mChunkSize = PRUint32(diff);
|
||||
|
||||
mChunk = new char[mChunkSize];
|
||||
|
|
|
@ -287,7 +287,7 @@ nsInputStreamPump::Init(nsIInputStream *stream,
|
|||
NS_ENSURE_TRUE(mState == STATE_IDLE, NS_ERROR_IN_PROGRESS);
|
||||
|
||||
mStreamOffset = PRUint64(streamPos);
|
||||
if (nsInt64(streamLen) >= nsInt64(0))
|
||||
if (PRInt64(streamLen) >= PRInt64(0))
|
||||
mStreamLength = PRUint64(streamLen);
|
||||
mStream = stream;
|
||||
mSegSize = segsize;
|
||||
|
|
|
@ -54,7 +54,6 @@
|
|||
#include "nsAutoPtr.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "netCore.h"
|
||||
#include "nsInt64.h"
|
||||
#include "prmem.h"
|
||||
#include "plstr.h"
|
||||
#include "prnetdb.h"
|
||||
|
|
|
@ -45,7 +45,6 @@
|
|||
#include "nsSocketTransportService2.h"
|
||||
#include "nsString.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsInt64.h"
|
||||
|
||||
#include "nsISocketTransport.h"
|
||||
#include "nsIInterfaceRequestor.h"
|
||||
|
|
|
@ -39,7 +39,6 @@
|
|||
#include "nsXPCOMCIDInternal.h"
|
||||
#include "nsNetSegmentUtils.h"
|
||||
#include "nsAutoLock.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsTransportUtils.h"
|
||||
#include "nsStreamUtils.h"
|
||||
#include "nsNetError.h"
|
||||
|
|
|
@ -43,7 +43,6 @@
|
|||
#include "nsFTPChannel.h"
|
||||
#include "nsBaseContentStream.h"
|
||||
|
||||
#include "nsInt64.h"
|
||||
#include "nsIThread.h"
|
||||
#include "nsIRunnable.h"
|
||||
#include "nsISocketTransportService.h"
|
||||
|
|
|
@ -64,7 +64,6 @@
|
|||
#include "prprf.h"
|
||||
#include "prnetdb.h"
|
||||
#include "nsEscape.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsStreamUtils.h"
|
||||
#include "nsIOService.h"
|
||||
#include "nsICacheService.h"
|
||||
|
@ -2501,20 +2500,20 @@ nsHttpChannel::CheckCache()
|
|||
// size of the cached content, then the cached response is partial...
|
||||
// either we need to issue a byte range request or we need to refetch
|
||||
// the entire document.
|
||||
nsInt64 contentLength = mCachedResponseHead->ContentLength();
|
||||
if (contentLength != nsInt64(-1)) {
|
||||
PRInt64 contentLength = mCachedResponseHead->ContentLength();
|
||||
if (contentLength != PRInt64(-1)) {
|
||||
PRUint32 size;
|
||||
rv = mCacheEntry->GetDataSize(&size);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
if (nsInt64(size) != contentLength) {
|
||||
if (PRInt64(size) != contentLength) {
|
||||
LOG(("Cached data size does not match the Content-Length header "
|
||||
"[content-length=%lld size=%u]\n", PRInt64(contentLength), size));
|
||||
|
||||
PRBool hasContentEncoding =
|
||||
mCachedResponseHead->PeekHeader(nsHttp::Content_Encoding)
|
||||
!= nsnull;
|
||||
if ((nsInt64(size) < contentLength) &&
|
||||
if ((PRInt64(size) < contentLength) &&
|
||||
size > 0 &&
|
||||
!hasContentEncoding &&
|
||||
mCachedResponseHead->IsResumable() &&
|
||||
|
@ -2834,7 +2833,7 @@ nsHttpChannel::ReadFromCache()
|
|||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
rv = nsInputStreamPump::Create(getter_AddRefs(mCachePump),
|
||||
stream, nsInt64(-1), nsInt64(-1), 0, 0,
|
||||
stream, PRInt64(-1), PRInt64(-1), 0, 0,
|
||||
PR_TRUE);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
|
|
|
@ -988,7 +988,7 @@ nsHttpTransaction::HandleContentStart()
|
|||
mContentLength = -1;
|
||||
}
|
||||
#if defined(PR_LOGGING)
|
||||
else if (mContentLength == nsInt64(-1))
|
||||
else if (mContentLength == PRInt64(-1))
|
||||
LOG(("waiting for the server to close the connection.\n"));
|
||||
#endif
|
||||
}
|
||||
|
@ -1028,21 +1028,21 @@ nsHttpTransaction::HandleContent(char *buf,
|
|||
rv = mChunkedDecoder->HandleChunkedContent(buf, count, contentRead, contentRemaining);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
}
|
||||
else if (mContentLength >= nsInt64(0)) {
|
||||
else if (mContentLength >= PRInt64(0)) {
|
||||
// HTTP/1.0 servers have been known to send erroneous Content-Length
|
||||
// headers. So, unless the connection is persistent, we must make
|
||||
// allowances for a possibly invalid Content-Length header. Thus, if
|
||||
// NOT persistent, we simply accept everything in |buf|.
|
||||
if (mConnection->IsPersistent()) {
|
||||
nsInt64 remaining = mContentLength - mContentRead;
|
||||
nsInt64 count64 = count;
|
||||
PRInt64 remaining = mContentLength - mContentRead;
|
||||
PRInt64 count64 = count;
|
||||
*contentRead = PR_MIN(count64, remaining);
|
||||
*contentRemaining = count - *contentRead;
|
||||
}
|
||||
else {
|
||||
*contentRead = count;
|
||||
// mContentLength might need to be increased...
|
||||
nsInt64 position = mContentRead + nsInt64(count);
|
||||
PRInt64 position = mContentRead + PRInt64(count);
|
||||
if (position > mContentLength) {
|
||||
mContentLength = position;
|
||||
//mResponseHead->SetContentLength(mContentLength);
|
||||
|
|
|
@ -44,7 +44,6 @@
|
|||
#include "nsAHttpTransaction.h"
|
||||
#include "nsAHttpConnection.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsInt64.h"
|
||||
|
||||
#include "nsIPipe.h"
|
||||
#include "nsIInputStream.h"
|
||||
|
@ -179,8 +178,8 @@ private:
|
|||
|
||||
nsCString mLineBuf; // may contain a partial line
|
||||
|
||||
nsInt64 mContentLength; // equals -1 if unknown
|
||||
nsInt64 mContentRead; // count of consumed content bytes
|
||||
PRInt64 mContentLength; // equals -1 if unknown
|
||||
PRInt64 mContentRead; // count of consumed content bytes
|
||||
|
||||
// After a 304/204 or other "no-content" style response we will skip over
|
||||
// up to MAX_INVALID_RESPONSE_BODY_SZ bytes when looking for the next
|
||||
|
|
|
@ -37,7 +37,6 @@
|
|||
|
||||
#include "nsMultiMixedConv.h"
|
||||
#include "nsMemory.h"
|
||||
#include "nsInt64.h"
|
||||
#include "plstr.h"
|
||||
#include "nsIHttpChannel.h"
|
||||
#include "nsIServiceManager.h"
|
||||
|
@ -980,7 +979,7 @@ nsMultiMixedConv::ParseHeaders(nsIChannel *aChannel, char *&aPtr,
|
|||
|
||||
mIsByteRangeRequest = PR_TRUE;
|
||||
if (mContentLength == LL_MAXUINT)
|
||||
mContentLength = PRUint64(PRInt64(mByteRangeEnd - mByteRangeStart + nsInt64(1)));
|
||||
mContentLength = PRUint64(PRInt64(mByteRangeEnd - mByteRangeStart + PRInt64(1)));
|
||||
}
|
||||
}
|
||||
*newLine = tmpChar;
|
||||
|
|
|
@ -43,7 +43,6 @@
|
|||
#include "nsString.h"
|
||||
#include "nsXPIDLString.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsIByteRangeRequest.h"
|
||||
#include "nsIMultiPartChannel.h"
|
||||
#include "nsAutoPtr.h"
|
||||
|
@ -102,8 +101,8 @@ protected:
|
|||
PRUint64 mContentLength;
|
||||
|
||||
PRBool mIsByteRangeRequest;
|
||||
nsInt64 mByteRangeStart;
|
||||
nsInt64 mByteRangeEnd;
|
||||
PRInt64 mByteRangeStart;
|
||||
PRInt64 mByteRangeEnd;
|
||||
|
||||
PRUint32 mPartID; // unique ID that can be used to identify
|
||||
// this part of the multipart document
|
||||
|
@ -190,8 +189,8 @@ protected:
|
|||
// The following members are for tracking the byte ranges in
|
||||
// multipart/mixed content which specified the 'Content-Range:'
|
||||
// header...
|
||||
nsInt64 mByteRangeStart;
|
||||
nsInt64 mByteRangeEnd;
|
||||
PRInt64 mByteRangeStart;
|
||||
PRInt64 mByteRangeEnd;
|
||||
PRBool mIsByteRangeRequest;
|
||||
|
||||
PRUint32 mCurrentPartID;
|
||||
|
|
|
@ -87,8 +87,6 @@
|
|||
#include "prlog.h"
|
||||
#include "prtime.h"
|
||||
|
||||
#include "nsInt64.h"
|
||||
|
||||
namespace TestProtocols {
|
||||
|
||||
#if defined(PR_LOGGING)
|
||||
|
@ -195,7 +193,7 @@ public:
|
|||
NS_DECL_ISUPPORTS
|
||||
|
||||
const char* Name() { return mURLString.get(); }
|
||||
nsInt64 mBytesRead;
|
||||
PRInt64 mBytesRead;
|
||||
PRTime mTotalTime;
|
||||
PRTime mConnectTime;
|
||||
nsCString mURLString;
|
||||
|
@ -541,9 +539,9 @@ InputTestConsumer::OnStopRequest(nsIRequest *request, nsISupports* context,
|
|||
LOG(("\tTime to connect: %.3f seconds\n", connectTime));
|
||||
LOG(("\tTime to read: %.3f seconds.\n", readTime));
|
||||
LOG(("\tRead: %lld bytes.\n", info->mBytesRead.mValue));
|
||||
if (info->mBytesRead == nsInt64(0)) {
|
||||
if (info->mBytesRead == PRInt64(0)) {
|
||||
} else if (readTime > 0.0) {
|
||||
LOG(("\tThroughput: %.0f bps.\n", (PRFloat64)(info->mBytesRead*nsInt64(8))/readTime));
|
||||
LOG(("\tThroughput: %.0f bps.\n", (PRFloat64)(info->mBytesRead*PRInt64(8))/readTime));
|
||||
} else {
|
||||
LOG(("\tThroughput: REAL FAST!!\n"));
|
||||
}
|
||||
|
|
|
@ -225,12 +225,12 @@ RunTest(nsIFile *srcFile, nsIFile *destFile)
|
|||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
nsCOMPtr<nsITransport> srcTransport;
|
||||
rv = sts->CreateInputTransport(srcStr, nsInt64(-1), nsInt64(-1), PR_TRUE,
|
||||
rv = sts->CreateInputTransport(srcStr, PRInt64(-1), PRInt64(-1), PR_TRUE,
|
||||
getter_AddRefs(srcTransport));
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
nsCOMPtr<nsITransport> destTransport;
|
||||
rv = sts->CreateOutputTransport(destStr, nsInt64(-1), nsInt64(-1), PR_TRUE,
|
||||
rv = sts->CreateOutputTransport(destStr, PRInt64(-1), PRInt64(-1), PR_TRUE,
|
||||
getter_AddRefs(destTransport));
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
|
@ -270,7 +270,7 @@ RunBlockingTest(nsIFile *srcFile, nsIFile *destFile)
|
|||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
nsCOMPtr<nsITransport> destTransport;
|
||||
rv = sts->CreateOutputTransport(fileOut, nsInt64(-1), nsInt64(-1),
|
||||
rv = sts->CreateOutputTransport(fileOut, PRInt64(-1), PRInt64(-1),
|
||||
PR_TRUE, getter_AddRefs(destTransport));
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
|
|
|
@ -45,7 +45,6 @@
|
|||
#include "nsISSLStatusProvider.h"
|
||||
#include "nsStrictTransportSecurityService.h"
|
||||
#include "nsIURI.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsNetUtil.h"
|
||||
#include "nsThreadUtils.h"
|
||||
#include "nsStringGlue.h"
|
||||
|
|
|
@ -94,7 +94,6 @@
|
|||
#include "nsReadableUtils.h"
|
||||
#include "nsIDateTimeFormat.h"
|
||||
#include "prtypes.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsTime.h"
|
||||
#include "nsIEntropyCollector.h"
|
||||
#include "nsIBufEntropyCollector.h"
|
||||
|
|
|
@ -107,8 +107,8 @@ struct nsRequestInfo : public PLDHashEntryHdr
|
|||
}
|
||||
|
||||
const void* mKey; // Must be first for the pldhash stubs to work
|
||||
nsInt64 mCurrentProgress;
|
||||
nsInt64 mMaxProgress;
|
||||
PRInt64 mCurrentProgress;
|
||||
PRInt64 mMaxProgress;
|
||||
PRBool mUploading;
|
||||
|
||||
PRBool mIsDone;
|
||||
|
@ -151,6 +151,11 @@ struct nsListenerInfo {
|
|||
nsDocLoader::nsDocLoader()
|
||||
: mParent(nsnull),
|
||||
mListenerInfoList(8),
|
||||
mCurrentSelfProgress(0),
|
||||
mMaxSelfProgress(0),
|
||||
mCurrentTotalProgress(0),
|
||||
mMaxTotalProgress(0),
|
||||
mCompletedTotalProgress(0),
|
||||
mIsLoadingDocument(PR_FALSE),
|
||||
mIsRestoringDocument(PR_FALSE),
|
||||
mDontFlushLayout(PR_FALSE),
|
||||
|
@ -598,7 +603,7 @@ nsDocLoader::OnStopRequest(nsIRequest *aRequest,
|
|||
if (info) {
|
||||
info->mIsDone = PR_TRUE;
|
||||
|
||||
nsInt64 oldMax = info->mMaxProgress;
|
||||
PRInt64 oldMax = info->mMaxProgress;
|
||||
|
||||
info->mMaxProgress = info->mCurrentProgress;
|
||||
|
||||
|
@ -607,7 +612,7 @@ nsDocLoader::OnStopRequest(nsIRequest *aRequest,
|
|||
// finished loading, then use this new data to try to calculate a
|
||||
// mMaxSelfProgress...
|
||||
//
|
||||
if ((oldMax < nsInt64(0)) && (mMaxSelfProgress < nsInt64(0))) {
|
||||
if ((oldMax < PRInt64(0)) && (mMaxSelfProgress < PRInt64(0))) {
|
||||
mMaxSelfProgress = CalculateMaxProgress();
|
||||
}
|
||||
|
||||
|
@ -1015,31 +1020,31 @@ nsDocLoader::GetIsLoadingDocument(PRBool *aIsLoadingDocument)
|
|||
|
||||
PRInt64 nsDocLoader::GetMaxTotalProgress()
|
||||
{
|
||||
nsInt64 newMaxTotal = 0;
|
||||
PRInt64 newMaxTotal = 0;
|
||||
|
||||
PRInt32 count = mChildList.Count();
|
||||
nsCOMPtr<nsIWebProgress> webProgress;
|
||||
for (PRInt32 i=0; i < count; i++)
|
||||
{
|
||||
nsInt64 individualProgress = 0;
|
||||
PRInt64 individualProgress = 0;
|
||||
nsIDocumentLoader* docloader = ChildAt(i);
|
||||
if (docloader)
|
||||
{
|
||||
// Cast is safe since all children are nsDocLoader too
|
||||
individualProgress = ((nsDocLoader *) docloader)->GetMaxTotalProgress();
|
||||
}
|
||||
if (individualProgress < nsInt64(0)) // if one of the elements doesn't know it's size
|
||||
if (individualProgress < PRInt64(0)) // if one of the elements doesn't know it's size
|
||||
// then none of them do
|
||||
{
|
||||
newMaxTotal = nsInt64(-1);
|
||||
newMaxTotal = PRInt64(-1);
|
||||
break;
|
||||
}
|
||||
else
|
||||
newMaxTotal += individualProgress;
|
||||
}
|
||||
|
||||
nsInt64 progress = -1;
|
||||
if (mMaxSelfProgress >= nsInt64(0) && newMaxTotal >= nsInt64(0))
|
||||
PRInt64 progress = -1;
|
||||
if (mMaxSelfProgress >= PRInt64(0) && newMaxTotal >= PRInt64(0))
|
||||
progress = newMaxTotal + mMaxSelfProgress;
|
||||
|
||||
return progress;
|
||||
|
@ -1055,7 +1060,7 @@ NS_IMETHODIMP nsDocLoader::OnProgress(nsIRequest *aRequest, nsISupports* ctxt,
|
|||
PRUint64 aProgress, PRUint64 aProgressMax)
|
||||
{
|
||||
nsRequestInfo *info;
|
||||
nsInt64 progressDelta = 0;
|
||||
PRInt64 progressDelta = 0;
|
||||
|
||||
//
|
||||
// Update the RequestInfo entry with the new progress data
|
||||
|
@ -1063,7 +1068,7 @@ NS_IMETHODIMP nsDocLoader::OnProgress(nsIRequest *aRequest, nsISupports* ctxt,
|
|||
info = GetRequestInfo(aRequest);
|
||||
if (info) {
|
||||
// suppress sending STATE_TRANSFERRING if this is upload progress (see bug 240053)
|
||||
if (!info->mUploading && (nsInt64(0) == info->mCurrentProgress) && (nsInt64(0) == info->mMaxProgress)) {
|
||||
if (!info->mUploading && (PRInt64(0) == info->mCurrentProgress) && (PRInt64(0) == info->mMaxProgress)) {
|
||||
//
|
||||
// If we receive an OnProgress event from a toplevel channel that the URI Loader
|
||||
// has not yet targeted, then we must suppress the event. This is necessary to
|
||||
|
@ -1088,8 +1093,8 @@ NS_IMETHODIMP nsDocLoader::OnProgress(nsIRequest *aRequest, nsISupports* ctxt,
|
|||
mMaxSelfProgress += PRInt64(aProgressMax);
|
||||
info->mMaxProgress = PRInt64(aProgressMax);
|
||||
} else {
|
||||
mMaxSelfProgress = nsInt64(-1);
|
||||
info->mMaxProgress = nsInt64(-1);
|
||||
mMaxSelfProgress = PRInt64(-1);
|
||||
info->mMaxProgress = PRInt64(-1);
|
||||
}
|
||||
|
||||
// Send a STATE_TRANSFERRING notification for the request.
|
||||
|
@ -1111,7 +1116,7 @@ NS_IMETHODIMP nsDocLoader::OnProgress(nsIRequest *aRequest, nsISupports* ctxt,
|
|||
}
|
||||
|
||||
// Update the current progress count...
|
||||
progressDelta = nsInt64(PRInt64(aProgress)) - info->mCurrentProgress;
|
||||
progressDelta = PRInt64(aProgress) - info->mCurrentProgress;
|
||||
mCurrentSelfProgress += progressDelta;
|
||||
|
||||
info->mCurrentProgress = PRInt64(aProgress);
|
||||
|
@ -1565,10 +1570,10 @@ CalcMaxProgressCallback(PLDHashTable *table, PLDHashEntryHdr *hdr,
|
|||
PRUint32 number, void *arg)
|
||||
{
|
||||
const nsRequestInfo *info = static_cast<const nsRequestInfo *>(hdr);
|
||||
nsInt64 *max = static_cast<nsInt64 *>(arg);
|
||||
PRInt64 *max = static_cast<PRInt64 *>(arg);
|
||||
|
||||
if (info->mMaxProgress < info->mCurrentProgress) {
|
||||
*max = nsInt64(-1);
|
||||
*max = PRInt64(-1);
|
||||
|
||||
return PL_DHASH_STOP;
|
||||
}
|
||||
|
@ -1580,7 +1585,7 @@ CalcMaxProgressCallback(PLDHashTable *table, PLDHashEntryHdr *hdr,
|
|||
|
||||
PRInt64 nsDocLoader::CalculateMaxProgress()
|
||||
{
|
||||
nsInt64 max = mCompletedTotalProgress;
|
||||
PRInt64 max = mCompletedTotalProgress;
|
||||
PL_DHashTableEnumerate(&mRequestInfoHash, CalcMaxProgressCallback, &max);
|
||||
return max;
|
||||
}
|
||||
|
|
|
@ -57,7 +57,6 @@
|
|||
#include "nsIChannelEventSink.h"
|
||||
#include "nsISecurityEventSink.h"
|
||||
#include "nsISupportsPriority.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "pldhash.h"
|
||||
|
||||
|
@ -226,14 +225,14 @@ protected:
|
|||
// feedback interfaces that travis cooked up.
|
||||
PRInt32 mProgressStateFlags;
|
||||
|
||||
nsInt64 mCurrentSelfProgress;
|
||||
nsInt64 mMaxSelfProgress;
|
||||
PRInt64 mCurrentSelfProgress;
|
||||
PRInt64 mMaxSelfProgress;
|
||||
|
||||
nsInt64 mCurrentTotalProgress;
|
||||
nsInt64 mMaxTotalProgress;
|
||||
PRInt64 mCurrentTotalProgress;
|
||||
PRInt64 mMaxTotalProgress;
|
||||
|
||||
PLDHashTable mRequestInfoHash;
|
||||
nsInt64 mCompletedTotalProgress;
|
||||
PRInt64 mCompletedTotalProgress;
|
||||
|
||||
/*
|
||||
* This flag indicates that the loader is loading a document. It is set
|
||||
|
|
|
@ -49,8 +49,6 @@
|
|||
#include "prlog.h"
|
||||
#include "prtime.h"
|
||||
|
||||
#include "nsInt64.h"
|
||||
|
||||
#include "nsIExternalHelperAppService.h"
|
||||
#include "nsIExternalProtocolService.h"
|
||||
#include "nsIWebProgressListener2.h"
|
||||
|
@ -341,8 +339,8 @@ protected:
|
|||
PRBool mTempFileIsExecutable;
|
||||
|
||||
PRTime mTimeDownloadStarted;
|
||||
nsInt64 mContentLength;
|
||||
nsInt64 mProgress; /**< Number of bytes received (for sending progress notifications). */
|
||||
PRInt64 mContentLength;
|
||||
PRInt64 mProgress; /**< Number of bytes received (for sending progress notifications). */
|
||||
|
||||
/**
|
||||
* When we are told to save the temp file to disk (in a more permament
|
||||
|
|
|
@ -53,7 +53,6 @@
|
|||
#include "nsIPrefBranch.h"
|
||||
#include "nsIPrefService.h"
|
||||
#include "nsRegion.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsHashtable.h"
|
||||
#include "nsCOMArray.h"
|
||||
#include "nsThreadUtils.h"
|
||||
|
|
|
@ -91,7 +91,6 @@
|
|||
#include "mozilla/FunctionTimer.h"
|
||||
#include "ManifestParser.h"
|
||||
|
||||
#include "nsInt64.h"
|
||||
#include "nsManifestLineReader.h"
|
||||
#include "mozilla/GenericFactory.h"
|
||||
#include "nsSupportsPrimitives.h"
|
||||
|
|
|
@ -100,7 +100,6 @@ EXPORTS = \
|
|||
nsHashtable.h \
|
||||
nsIByteBuffer.h \
|
||||
nsIUnicharBuffer.h \
|
||||
nsInt64.h \
|
||||
nsMathUtils.h \
|
||||
nsObserverService.h \
|
||||
nsRecyclingAllocator.h \
|
||||
|
|
|
@ -1,44 +0,0 @@
|
|||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is mozilla.org code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Netscape Communications Corporation.
|
||||
* Portions created by the Initial Developer are Copyright (C) 1998
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either of the GNU General Public License Version 2 or later (the "GPL"),
|
||||
* or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#ifndef nsInt64_h__
|
||||
#define nsInt64_h__
|
||||
|
||||
typedef PRInt64 nsInt64;
|
||||
typedef PRUint64 nsUint64;
|
||||
|
||||
#endif // nsInt64_h__
|
|
@ -56,7 +56,6 @@
|
|||
|
||||
#include "nsBinaryStream.h"
|
||||
#include "nsFastLoadFile.h"
|
||||
#include "nsInt64.h"
|
||||
#ifdef XP_UNIX
|
||||
#include <sys/mman.h>
|
||||
#endif
|
||||
|
|
|
@ -51,7 +51,6 @@
|
|||
#include "nsISeekableStream.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsCOMArray.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsIIPCSerializable.h"
|
||||
#include "nsIClassInfoImpl.h"
|
||||
|
||||
|
@ -384,7 +383,7 @@ nsMultiplexInputStream::Tell(PRInt64 *_retval)
|
|||
return mStatus;
|
||||
|
||||
nsresult rv;
|
||||
nsInt64 ret64 = 0;
|
||||
PRInt64 ret64 = 0;
|
||||
PRUint32 i, last;
|
||||
last = mStartedReadingCurrent ? mCurrentStream+1 : mCurrentStream;
|
||||
for (i = 0; i < last; ++i) {
|
||||
|
|
|
@ -45,7 +45,6 @@
|
|||
#include "nsCOMPtr.h"
|
||||
#include "nsCRT.h"
|
||||
#include "prlog.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsIClassInfoImpl.h"
|
||||
#include "nsAtomicRefcnt.h"
|
||||
|
||||
|
@ -152,7 +151,7 @@ private:
|
|||
|
||||
// separate refcnt so that we know when to close the consumer
|
||||
nsrefcnt mReaderRefCnt;
|
||||
nsInt64 mLogicalOffset;
|
||||
PRInt64 mLogicalOffset;
|
||||
PRPackedBool mBlocking;
|
||||
|
||||
// these variables can only be accessed while inside the pipe's monitor
|
||||
|
@ -206,7 +205,7 @@ private:
|
|||
|
||||
// separate refcnt so that we know when to close the producer
|
||||
nsrefcnt mWriterRefCnt;
|
||||
nsInt64 mLogicalOffset;
|
||||
PRInt64 mLogicalOffset;
|
||||
PRPackedBool mBlocking;
|
||||
|
||||
// these variables can only be accessed while inside the pipe's monitor
|
||||
|
|
|
@ -54,7 +54,6 @@
|
|||
#include "nsIInputStream.h"
|
||||
#include "nsISeekableStream.h"
|
||||
#include "prlog.h"
|
||||
#include "nsInt64.h"
|
||||
|
||||
#if defined(PR_LOGGING)
|
||||
//
|
||||
|
|
|
@ -61,7 +61,6 @@
|
|||
#include "nsReadableUtils.h"
|
||||
#include "nsISeekableStream.h"
|
||||
#include "nsISupportsPrimitives.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsCRT.h"
|
||||
#include "prerror.h"
|
||||
#include "plstr.h"
|
||||
|
|
|
@ -66,7 +66,6 @@
|
|||
#include "nsMemory.h"
|
||||
|
||||
#include "nsCOMArray.h"
|
||||
#include "nsInt64.h"
|
||||
#include "nsQuickSort.h"
|
||||
|
||||
#include "nsXPIDLString.h"
|
||||
|
|
|
@ -40,7 +40,6 @@
|
|||
#include "nscore.h"
|
||||
#include "prprf.h"
|
||||
#include "plstr.h"
|
||||
#include "nsInt64.h"
|
||||
|
||||
#include "nsISupports.h"
|
||||
#include "nsIServiceManager.h"
|
||||
|
|
Загрузка…
Ссылка в новой задаче