| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 function FindProxyForURL(url, host) { | |
| 6 if (host != 'hang') | |
| 7 return 'PROXY ' + host + ':88'; | |
| 8 | |
| 9 var ip = dnsResolve("host1"); | |
| 10 | |
| 11 // The following may or may not be executed, even if dnsResolve() terminates | |
| 12 // the script execution. | |
| 13 dnsResolveEx("host2"); | |
| 14 dnsResolveEx("host3"); | |
| 15 alert("hahaha"); | |
| 16 | |
| 17 // Hang! | |
| 18 for (;;) {} | |
| 19 | |
| 20 // The following definitely won't be executed, since control should never | |
| 21 // make it past the preceding hang. | |
| 22 dnsResolve("host4"); | |
| 23 dnsResolve("host5"); | |
| 24 alert("uhm..."); | |
| 25 throw "not reached"; | |
| 26 } | |
| OLD | NEW |