| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 | 2 |
| 3 # Copyright 2015 The Crashpad Authors. All rights reserved. | 3 # Copyright 2015 The Crashpad Authors. All rights reserved. |
| 4 # | 4 # |
| 5 # Licensed under the Apache License, Version 2.0 (the "License"); | 5 # Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 # you may not use this file except in compliance with the License. | 6 # you may not use this file except in compliance with the License. |
| 7 # You may obtain a copy of the License at | 7 # You may obtain a copy of the License at |
| 8 # | 8 # |
| 9 # http://www.apache.org/licenses/LICENSE-2.0 | 9 # http://www.apache.org/licenses/LICENSE-2.0 |
| 10 # | 10 # |
| (...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 out.Check(r'TEB at', 'found the TEB') | 214 out.Check(r'TEB at', 'found the TEB') |
| 215 out.Check(r'ExceptionList:\s+[0-9a-fA-F]+', 'some valid teb data') | 215 out.Check(r'ExceptionList:\s+[0-9a-fA-F]+', 'some valid teb data') |
| 216 out.Check(r'LastErrorValue:\s+2', 'correct LastErrorValue') | 216 out.Check(r'LastErrorValue:\s+2', 'correct LastErrorValue') |
| 217 | 217 |
| 218 out = CdbRun(cdb_path, dump_path, '!gle') | 218 out = CdbRun(cdb_path, dump_path, '!gle') |
| 219 out.Check('LastErrorValue: \(Win32\) 0x2 \(2\) - The system cannot find the ' | 219 out.Check('LastErrorValue: \(Win32\) 0x2 \(2\) - The system cannot find the ' |
| 220 'file specified.', '!gle gets last error') | 220 'file specified.', '!gle gets last error') |
| 221 out.Check('LastStatusValue: \(NTSTATUS\) 0xc000000f - {File Not Found} The ' | 221 out.Check('LastStatusValue: \(NTSTATUS\) 0xc000000f - {File Not Found} The ' |
| 222 'file %hs does not exist.', '!gle gets last ntstatus') | 222 'file %hs does not exist.', '!gle gets last ntstatus') |
| 223 | 223 |
| 224 out = CdbRun(cdb_path, dump_path, '!locks') | 224 if False: |
| 225 out.Check(r'CritSec crashy_program!crashpad::`anonymous namespace\'::' | 225 # TODO(scottmg): Re-enable when we grab ntdll!RtlCriticalSectionList. |
| 226 r'g_test_critical_section', 'lock was captured') | 226 out = CdbRun(cdb_path, dump_path, '!locks') |
| 227 if platform.win32_ver()[0] != '7': | 227 out.Check(r'CritSec crashy_program!crashpad::`anonymous namespace\'::' |
| 228 # We can't allocate CRITICAL_SECTIONs with .DebugInfo on Win 7. | 228 r'g_test_critical_section', 'lock was captured') |
| 229 out.Check(r'\*\*\* Locked', 'lock debug info was captured, and is locked') | 229 if platform.win32_ver()[0] != '7': |
| 230 # We can't allocate CRITICAL_SECTIONs with .DebugInfo on Win 7. |
| 231 out.Check(r'\*\*\* Locked', 'lock debug info was captured, and is locked') |
| 230 | 232 |
| 231 out = CdbRun(cdb_path, dump_path, '!handle') | 233 out = CdbRun(cdb_path, dump_path, '!handle') |
| 232 out.Check(r'\d+ Handles', 'captured handles') | 234 out.Check(r'\d+ Handles', 'captured handles') |
| 233 out.Check(r'Event\s+\d+', 'capture some event handles') | 235 out.Check(r'Event\s+\d+', 'capture some event handles') |
| 234 out.Check(r'File\s+\d+', 'capture some file handles') | 236 out.Check(r'File\s+\d+', 'capture some file handles') |
| 235 | 237 |
| 236 out = CdbRun(cdb_path, destroyed_dump_path, '.ecxr;!peb;k 2') | 238 out = CdbRun(cdb_path, destroyed_dump_path, '.ecxr;!peb;k 2') |
| 237 out.Check(r'Ldr\.InMemoryOrderModuleList:.*\d+ \. \d+', 'PEB_LDR_DATA saved') | 239 out.Check(r'Ldr\.InMemoryOrderModuleList:.*\d+ \. \d+', 'PEB_LDR_DATA saved') |
| 238 out.Check(r'ntdll\.dll', 'ntdll present', re.IGNORECASE) | 240 out.Check(r'ntdll\.dll', 'ntdll present', re.IGNORECASE) |
| 239 | 241 |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 304 z7_dump_path, | 306 z7_dump_path, |
| 305 pipe_name) | 307 pipe_name) |
| 306 | 308 |
| 307 return 0 | 309 return 0 |
| 308 finally: | 310 finally: |
| 309 CleanUpTempDirs() | 311 CleanUpTempDirs() |
| 310 | 312 |
| 311 | 313 |
| 312 if __name__ == '__main__': | 314 if __name__ == '__main__': |
| 313 sys.exit(main(sys.argv[1:])) | 315 sys.exit(main(sys.argv[1:])) |
| OLD | NEW |