зеркало из https://github.com/mozilla/pjs.git
Fixed warnings.
This commit is contained in:
Родитель
874b7eab04
Коммит
1c51d9a00b
|
@ -310,7 +310,6 @@ extern "C" NS_EXPORT int DebugRobot(
|
|||
while (!g_bReadyForNextUrl) {
|
||||
if (yieldProc != NULL) {
|
||||
#ifdef NECKO
|
||||
char* spec;
|
||||
(void)url->GetSpec(&spec);
|
||||
(*yieldProc)(spec);
|
||||
nsCRT::free(spec);
|
||||
|
|
|
@ -145,7 +145,6 @@ GetScheme(const char* inURI, char* *scheme)
|
|||
if (!inURI) return NS_ERROR_NULL_POINTER;
|
||||
char c;
|
||||
const char* URI = inURI;
|
||||
PRUint32 i = 0;
|
||||
PRUint32 length = 0;
|
||||
// skip leading white space
|
||||
while (isspace(*URI))
|
||||
|
|
|
@ -87,14 +87,14 @@ NS_IMETHODIMP
|
|||
nsSimpleURI::SetSpec(const char* aSpec)
|
||||
{
|
||||
nsAutoString spec(aSpec);
|
||||
PRUint32 pos = spec.Find(":");
|
||||
PRInt32 pos = spec.Find(":");
|
||||
if (pos == -1)
|
||||
return NS_ERROR_FAILURE;
|
||||
nsAutoString scheme;
|
||||
PRUint32 n = spec.Left(scheme, pos);
|
||||
PRInt32 n = spec.Left(scheme, pos);
|
||||
NS_ASSERTION(n == pos, "Left failed");
|
||||
nsAutoString path;
|
||||
PRUint32 count = spec.Length() - pos - 1;
|
||||
PRInt32 count = spec.Length() - pos - 1;
|
||||
n = spec.Mid(path, pos + 1, count);
|
||||
NS_ASSERTION(n == count, "Mid failed");
|
||||
if (mScheme)
|
||||
|
|
|
@ -84,7 +84,7 @@ public:
|
|||
rv = inStr->Read(buffer, len, &read);
|
||||
buffer[len] = '\0';
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
printf("CONTEXT %x: Received %d bytes and the following data: \n %s\n\n", ctxt, read, buffer);
|
||||
printf("CONTEXT %x: Received %u bytes and the following data: \n %s\n\n", ctxt, read, buffer);
|
||||
}
|
||||
nsAllocator::Free(buffer);
|
||||
|
||||
|
|
|
@ -310,7 +310,6 @@ extern "C" NS_EXPORT int DebugRobot(
|
|||
while (!g_bReadyForNextUrl) {
|
||||
if (yieldProc != NULL) {
|
||||
#ifdef NECKO
|
||||
char* spec;
|
||||
(void)url->GetSpec(&spec);
|
||||
(*yieldProc)(spec);
|
||||
nsCRT::free(spec);
|
||||
|
|
|
@ -341,7 +341,7 @@ nsDocLoaderImpl::Init()
|
|||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
PR_LOG(gDocLoaderLog, PR_LOG_DEBUG,
|
||||
("DocLoader:%p: load group %x.\n", this, mLoadGroup));
|
||||
("DocLoader:%p: load group %x.\n", this, mLoadGroup.get()));
|
||||
|
||||
rv = mLoadGroup->SetGroupListenerFactory(this);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
|
|
@ -341,7 +341,7 @@ nsDocLoaderImpl::Init()
|
|||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
PR_LOG(gDocLoaderLog, PR_LOG_DEBUG,
|
||||
("DocLoader:%p: load group %x.\n", this, mLoadGroup));
|
||||
("DocLoader:%p: load group %x.\n", this, mLoadGroup.get()));
|
||||
|
||||
rv = mLoadGroup->SetGroupListenerFactory(this);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
|
|
@ -224,7 +224,6 @@ nsPipe::GetReadSegment(PRUint32 segmentLogicalOffset,
|
|||
|
||||
PRInt32 offset = (PRInt32)segmentLogicalOffset;
|
||||
PRInt32 segCount = mBuffer.GetSegmentCount();
|
||||
PRBool atEnd = PR_FALSE;
|
||||
for (PRInt32 i = 0; i < segCount; i++) {
|
||||
char* segStart = mBuffer.GetSegment(i);
|
||||
char* segEnd = segStart + mBuffer.GetSegmentSize();
|
||||
|
|
Загрузка…
Ссылка в новой задаче