aboutsummaryrefslogtreecommitdiff
path: root/src/tools/linux/dump_syms/dump_syms.cc
diff options
context:
space:
mode:
authorted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e>2011-07-06 17:05:59 +0000
committerted.mielczarek <ted.mielczarek@4c0a9323-5329-0410-9bdc-e9ce6186880e>2011-07-06 17:05:59 +0000
commit3ca4a120de8ec3f35e972e4b23f527bb8f65c479 (patch)
tree0186b36bf01d54c7700c00c3c2cec21fbb382268 /src/tools/linux/dump_syms/dump_syms.cc
parentDump PUBLIC + CFI records from libraries without debug info on Linux, use .dy... (diff)
downloadbreakpad-3ca4a120de8ec3f35e972e4b23f527bb8f65c479.tar.xz
Add some unit tests for Linux WriteSymbolFile
This patch adds synth_elf::{StringTable,SymbolTable,ELF} classes to produce in-memory ELF files to properly test the Linux symbol dumping code. It also uses those classes to add some basic tests for the WriteSymbolFile function. R=jimb at http://breakpad.appspot.com/277001/show git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@794 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/tools/linux/dump_syms/dump_syms.cc')
-rw-r--r--src/tools/linux/dump_syms/dump_syms.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/tools/linux/dump_syms/dump_syms.cc b/src/tools/linux/dump_syms/dump_syms.cc
index 7d721a8c..f4c05cfc 100644
--- a/src/tools/linux/dump_syms/dump_syms.cc
+++ b/src/tools/linux/dump_syms/dump_syms.cc
@@ -27,6 +27,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#include <iostream>
#include <stdio.h>
#include <string>
@@ -46,7 +47,7 @@ int main(int argc, char **argv) {
if (argc == 3)
debug_dir = argv[2];
- if (!WriteSymbolFile(binary, debug_dir, stdout)) {
+ if (!WriteSymbolFile(binary, debug_dir, std::cout)) {
fprintf(stderr, "Failed to write symbol file.\n");
return 1;
}