diff --git a/netwerk/test/httpserver/httpd.js b/netwerk/test/httpserver/httpd.js index bf98ed326ef..732e299cc81 100644 --- a/netwerk/test/httpserver/httpd.js +++ b/netwerk/test/httpserver/httpd.js @@ -458,7 +458,7 @@ nsHttpServer.prototype = } }; gThreadManager.currentThread - .dispatch(stopEvent, Ci.nsIThreadManager.DISPATCH_NORMAL); + .dispatch(stopEvent, Ci.nsIThread.DISPATCH_NORMAL); } }, @@ -2599,7 +2599,7 @@ ServerHandler.prototype = // Seek (or read, if seeking isn't supported) to the correct offset so // the data sent to the client matches the requested range. if (fis instanceof Ci.nsISeekableStream) - fis.seek(Ci.nsISeekableStream.SEEK_SET, offset); + fis.seek(Ci.nsISeekableStream.NS_SEEK_SET, offset); else new ScriptableInputStream(fis).read(offset); } @@ -2613,7 +2613,7 @@ ServerHandler.prototype = function writeMore() { gThreadManager.currentThread - .dispatch(writeData, Ci.nsIThreadManager.DISPATCH_NORMAL); + .dispatch(writeData, Ci.nsIThread.DISPATCH_NORMAL); } var input = new BinaryInputStream(fis); @@ -3688,7 +3688,7 @@ Response.prototype = dumpn("*** canceling copy asynchronously..."); copier.cancel(Cr.NS_ERROR_UNEXPECTED); } - }, Ci.nsIThreadManager.DISPATCH_NORMAL); + }, Ci.nsIThread.DISPATCH_NORMAL); } else { @@ -3993,7 +3993,7 @@ WriteThroughCopier.prototype = } }; gThreadManager.currentThread - .dispatch(cancelEvent, Ci.nsIThreadManager.DISPATCH_NORMAL); + .dispatch(cancelEvent, Ci.nsIThread.DISPATCH_NORMAL); }, /** diff --git a/netwerk/test/httpserver/test/test_default_index_handler.js b/netwerk/test/httpserver/test/test_default_index_handler.js index fd427ac2c3f..e13868685ff 100644 --- a/netwerk/test/httpserver/test/test_default_index_handler.js +++ b/netwerk/test/httpserver/test/test_default_index_handler.js @@ -75,7 +75,7 @@ function createTestDirectory() // populate with test directories, files, etc. // Files must be in expected order of display on the index page! - files = []; + var files = []; makeFile("aa_directory", true, dir, files); makeFile("Ba_directory", true, dir, files); @@ -179,7 +179,7 @@ function hiddenDataCheck(bytes, uri, path) do_check_eq(link.textContent, f.name + sep); - var uri = ios.newURI(link.getAttribute("href"), null, top); + uri = ios.newURI(link.getAttribute("href"), null, top); do_check_eq(decodeURIComponent(uri.path), path + f.name + sep); } } @@ -259,7 +259,7 @@ function dataCheck(bytes, uri, path, dirEntries) do_check_eq(link.textContent, f.name + sep); - var uri = ios.newURI(link.getAttribute("href"), null, top); + uri = ios.newURI(link.getAttribute("href"), null, top); do_check_eq(decodeURIComponent(uri.path), path + f.name + sep); } } diff --git a/netwerk/test/httpserver/test/test_processasync.js b/netwerk/test/httpserver/test/test_processasync.js index b05f6f8e8b4..07b07d418bf 100644 --- a/netwerk/test/httpserver/test/test_processasync.js +++ b/netwerk/test/httpserver/test/test_processasync.js @@ -358,7 +358,7 @@ function handleAsyncOrdering(request, response) // intended for public use! If you do this in client code, expect me to // knowingly break your code by changing the variable name. :-P gThreadManager.currentThread - .dispatch(writeData, Ci.nsIThreadManager.DISPATCH_NORMAL); + .dispatch(writeData, Ci.nsIThread.DISPATCH_NORMAL); } step(); response.processAsync(); diff --git a/netwerk/test/httpserver/test/test_seizepower.js b/netwerk/test/httpserver/test/test_seizepower.js index 47d08ff52a9..65319d3a09b 100644 --- a/netwerk/test/httpserver/test/test_seizepower.js +++ b/netwerk/test/httpserver/test/test_seizepower.js @@ -86,7 +86,7 @@ function callASAPLater(fun) { fun(); } - }, Ci.nsIThreadManager.DISPATCH_NORMAL); + }, Ci.nsIThread.DISPATCH_NORMAL); } @@ -274,11 +274,11 @@ tests.push(test); data = "GET /thrown-exception?writeBeforeEmpty HTTP/1.0\r\n" + "\r\n"; -function checkThrownExceptionWriteBefore(data) +function checkThrownExceptionWriteBeforeEmpty(data) { do_check_eq(data, "preparing to throw..."); } -test = new RawTest("localhost", PORT, data, checkThrownExceptionWriteBefore), +test = new RawTest("localhost", PORT, data, checkThrownExceptionWriteBeforeEmpty), tests.push(test); data = "GET /thrown-exception HTTP/1.0\r\n" + diff --git a/netwerk/test/unit/test_redirect_caching.js b/netwerk/test/unit/test_redirect_caching.js index 04ec825a998..684ae17b273 100644 --- a/netwerk/test/unit/test_redirect_caching.js +++ b/netwerk/test/unit/test_redirect_caching.js @@ -30,7 +30,7 @@ function firstTimeThrough(request, buffer) { do_check_eq(buffer, responseBody); var chan = make_channel(randomURI); - chan.loadFlags |= Ci.nsICachingChannel.LOAD_FROM_CACHE; + chan.loadFlags |= Ci.nsIRequest.LOAD_FROM_CACHE; chan.asyncOpen(new ChannelListener(finish_test, null), null); } diff --git a/netwerk/test/unit/test_resumable_channel.js b/netwerk/test/unit/test_resumable_channel.js index b018f7c702b..8aacdb47cc0 100644 --- a/netwerk/test/unit/test_resumable_channel.js +++ b/netwerk/test/unit/test_resumable_channel.js @@ -320,7 +320,7 @@ function handleAuth(metadata, response) { // /auth function authHandler(metadata, response) { response.setHeader("Content-Type", "text/html", false); - body = handleAuth(metadata, response) ? "success" : "failure"; + var body = handleAuth(metadata, response) ? "success" : "failure"; response.bodyOutputStream.write(body, body.length); }