mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-23 18:14:13 +08:00
16a447bec5
The new function will be used in a subsequent patch to read a different stat field. The new code is believed to be equivalent to the old code, so there should be no change in GDB behaviour. The only material change was to use std::string and string_printf rather than a fixed char array to build the path to the stat file. Also, take the opportunity to move the function's documentation comment to the header file, to conform with GDB practice. Reviewed-By: Luis Machado <luis.machado@arm.com> Approved-By: Pedro Alves <pedro@palves.net>
31 lines
1.1 KiB
C
31 lines
1.1 KiB
C
/* Linux-specific functions to retrieve OS data.
|
|
|
|
Copyright (C) 2009-2024 Free Software Foundation, Inc.
|
|
|
|
This file is part of GDB.
|
|
|
|
This program is free software; you can redistribute it and/or modify
|
|
it under the terms of the GNU General Public License as published by
|
|
the Free Software Foundation; either version 3 of the License, or
|
|
(at your option) any later version.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU General Public License for more details.
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>. */
|
|
|
|
#ifndef NAT_LINUX_OSDATA_H
|
|
#define NAT_LINUX_OSDATA_H
|
|
|
|
/* Returns the CPU core that thread PTID is currently running on. */
|
|
|
|
extern int linux_common_core_of_thread (ptid_t ptid);
|
|
|
|
extern LONGEST linux_common_xfer_osdata (const char *annex, gdb_byte *readbuf,
|
|
ULONGEST offset, ULONGEST len);
|
|
|
|
#endif /* NAT_LINUX_OSDATA_H */
|