зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1416252 - Remove conditional catch consumers in modules/libjar/. r=mossop
This commit is contained in:
Родитель
4ac42f3d2f
Коммит
5e6c2faca5
|
@ -5,8 +5,11 @@ function run_test() {
|
|||
try {
|
||||
zipCache.getZip(null);
|
||||
do_throw("Shouldn't get here!");
|
||||
} catch (e if ((e instanceof Components.interfaces.nsIException) &&
|
||||
(e.result == Components.results.NS_ERROR_INVALID_POINTER))) {
|
||||
} catch (e) {
|
||||
if (!(e instanceof Components.interfaces.nsIException &&
|
||||
e.result == Components.results.NS_ERROR_INVALID_POINTER)) {
|
||||
throw e;
|
||||
}
|
||||
// do nothing, this test passes
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,8 +4,11 @@ function run_test() {
|
|||
try {
|
||||
zReader.open(null);
|
||||
do_throw("Shouldn't get here!");
|
||||
} catch (e if (e instanceof Components.interfaces.nsIException &&
|
||||
e.result == Components.results.NS_ERROR_NULL_POINTER)) {
|
||||
} catch (e) {
|
||||
if (!(e instanceof Components.interfaces.nsIException &&
|
||||
e.result == Components.results.NS_ERROR_NULL_POINTER)) {
|
||||
throw e;
|
||||
}
|
||||
// do nothing, this test passes
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,8 +21,11 @@ function run_test()
|
|||
zipW.open(invalidFile, PR_RDWR);
|
||||
do_throw("Should have thrown NS_ERROR_FILE_CORRUPTED on " +
|
||||
invalidArchive + " !");
|
||||
} catch (e if (e instanceof Ci.nsIException &&
|
||||
e.result == Components.results.NS_ERROR_FILE_CORRUPTED)) {
|
||||
} catch (e) {
|
||||
if (!(e instanceof Ci.nsIException &&
|
||||
e.result == Components.results.NS_ERROR_FILE_CORRUPTED)) {
|
||||
throw e;
|
||||
}
|
||||
// do nothing
|
||||
}
|
||||
});
|
||||
|
|
Загрузка…
Ссылка в новой задаче