src/share/vm/utilities/elfStringTable.hpp

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. --- 1,7 ---- /* ! * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation.
*** 20,31 **** * or visit www.oracle.com if you need additional information or have any * questions. * */ ! #ifndef __ELF_STRING_TABLE_HPP ! #define __ELF_STRING_TABLE_HPP #if !defined(_WINDOWS) && !defined(__APPLE__) #include "memory/allocation.hpp" #include "utilities/decoder.hpp" --- 20,31 ---- * or visit www.oracle.com if you need additional information or have any * questions. * */ ! #ifndef SHARE_VM_UTILITIES_ELF_STRING_TABLE_HPP ! #define SHARE_VM_UTILITIES_ELF_STRING_TABLE_HPP #if !defined(_WINDOWS) && !defined(__APPLE__) #include "memory/allocation.hpp" #include "utilities/decoder.hpp"
*** 33,45 **** // The string table represents a string table section in an elf file. // Whenever there is enough memory, it will load whole string table as // one blob. Otherwise, it will load string from file when requested. - - #define MAX_SYMBOL_LEN 256 - class ElfStringTable: CHeapObj { friend class ElfFile; public: ElfStringTable(FILE* file, Elf_Shdr shdr, int index); ~ElfStringTable(); --- 33,42 ----
*** 46,59 **** // section index int index() { return m_index; }; // get string at specified offset ! const char* string_at(int offset); // get status code ! Decoder::decoder_status get_status() { return m_status; }; protected: ElfStringTable* m_next; // section index --- 43,56 ---- // section index int index() { return m_index; }; // get string at specified offset ! bool string_at(int offset, char* buf, int buflen); // get status code ! NullDecoder::decoder_status get_status() { return m_status; }; protected: ElfStringTable* m_next; // section index
*** 67,81 **** FILE* m_file; // section header Elf_Shdr m_shdr; - // buffer for reading individual string - char m_symbol[MAX_SYMBOL_LEN]; - // error code ! Decoder::decoder_status m_status; }; ! #endif // _WINDOWS ! #endif // __ELF_STRING_TABLE_HPP --- 64,75 ---- FILE* m_file; // section header Elf_Shdr m_shdr; // error code ! NullDecoder::decoder_status m_status; }; ! #endif // _WINDOWS and _APPLE ! #endif // SHARE_VM_UTILITIES_ELF_STRING_TABLE_HPP