| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 | 2 |
| 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
| 4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
| 6 | 6 |
| 7 # Script to generate stackdumps from a machine or dmp files. | 7 # Script to generate stackdumps from a machine or dmp files. |
| 8 | 8 |
| 9 # Load common constants. This should be the first executable line. | 9 # Load common constants. This should be the first executable line. |
| 10 # The path to common.sh should be relative to your script's location. | 10 # The path to common.sh should be relative to your script's location. |
| 11 | 11 |
| 12 . "$(dirname $0)/common.sh" | 12 . "$(dirname $0)/common.sh" |
| 13 . "$(dirname $0)/remote_access.sh" | 13 . "$(dirname $0)/remote_access.sh" |
| 14 | 14 |
| 15 restart_in_chroot_if_needed $* | 15 assert_inside_chroot |
| 16 | 16 |
| 17 MINIDUMP_DUMP=/usr/bin/minidump_dump | 17 MINIDUMP_DUMP=/usr/bin/minidump_dump |
| 18 MINIDUMP_STACKWALK=/usr/bin/minidump_stackwalk | 18 MINIDUMP_STACKWALK=/usr/bin/minidump_stackwalk |
| 19 USING_REMOTE=0 | 19 USING_REMOTE=0 |
| 20 | 20 |
| 21 get_default_board | 21 get_default_board |
| 22 | 22 |
| 23 DEFINE_string board "${DEFAULT_BOARD}" \ | 23 DEFINE_string board "${DEFAULT_BOARD}" \ |
| 24 "The board for which you are building autotest" | 24 "The board for which you are building autotest" |
| 25 DEFINE_string breakpad_root "" \ | 25 DEFINE_string breakpad_root "" \ |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 162 ${MINIDUMP_STACKWALK} "${dump}" "${FLAGS_breakpad_root}" 2> /dev/null | 162 ${MINIDUMP_STACKWALK} "${dump}" "${FLAGS_breakpad_root}" 2> /dev/null |
| 163 else | 163 else |
| 164 info "Dumping kcrash $(basename ${dump}):" | 164 info "Dumping kcrash $(basename ${dump}):" |
| 165 cat "${dump}" | 165 cat "${dump}" |
| 166 fi | 166 fi |
| 167 echo "" | 167 echo "" |
| 168 done | 168 done |
| 169 } | 169 } |
| 170 | 170 |
| 171 main "$@" | 171 main "$@" |
| OLD | NEW |