aboutsummaryrefslogtreecommitdiff
path: root/gdb/common
diff options
context:
space:
mode:
authorStan Shebs <shebs@codesourcery.com>2012-06-28 23:44:26 +0000
committerStan Shebs <shebs@codesourcery.com>2012-06-28 23:44:26 +0000
commit71caed8383ce5ad0277bf0c1feaec40911fc040c (patch)
treebf5f59fd18c8feb9ecba020d7941445e6577c43f /gdb/common
parent37ce89ebb295e6ed0fc0bf5a4eb2e718ed0fb2ee (diff)
downloadgdb-71caed8383ce5ad0277bf0c1feaec40911fc040c.zip
gdb-71caed8383ce5ad0277bf0c1feaec40911fc040c.tar.gz
gdb-71caed8383ce5ad0277bf0c1feaec40911fc040c.tar.bz2
* osdata.c (info_osdata_command): Filter out "Title" columns
from non-MI uses. * common/linux-osdata.c (struct osdata_type): Add title field. (osdata_table): Add titles to each entry. (linux_command_xfer_osdata): Add a column for title data. * gdb.texinfo (Miscellaneous GDB/MI Commands): Update -info-os example, add note about title column.
Diffstat (limited to 'gdb/common')
-rw-r--r--gdb/common/linux-osdata.c23
1 files changed, 13 insertions, 10 deletions
diff --git a/gdb/common/linux-osdata.c b/gdb/common/linux-osdata.c
index 1086d10..6488963 100644
--- a/gdb/common/linux-osdata.c
+++ b/gdb/common/linux-osdata.c
@@ -1543,26 +1543,27 @@ linux_xfer_osdata_modules (gdb_byte *readbuf,
struct osdata_type {
char *type;
+ char *title;
char *description;
LONGEST (*getter) (gdb_byte *readbuf, ULONGEST offset, LONGEST len);
} osdata_table[] = {
- { "processes", "Listing of all processes",
+ { "processes", "Processes", "Listing of all processes",
linux_xfer_osdata_processes },
- { "procgroups", "Listing of all process groups",
+ { "procgroups", "Process groups", "Listing of all process groups",
linux_xfer_osdata_processgroups },
- { "threads", "Listing of all threads",
+ { "threads", "Threads", "Listing of all threads",
linux_xfer_osdata_threads },
- { "files", "Listing of all file descriptors",
+ { "files", "File descriptors", "Listing of all file descriptors",
linux_xfer_osdata_fds },
- { "sockets", "Listing of all internet-domain sockets",
+ { "sockets", "Sockets", "Listing of all internet-domain sockets",
linux_xfer_osdata_isockets },
- { "shm", "Listing of all shared-memory regions",
+ { "shm", "Shared-memory regions", "Listing of all shared-memory regions",
linux_xfer_osdata_shm },
- { "semaphores", "Listing of all semaphores",
+ { "semaphores", "Semaphores", "Listing of all semaphores",
linux_xfer_osdata_sem },
- { "msg", "Listing of all message queues",
+ { "msg", "Message queues", "Listing of all message queues",
linux_xfer_osdata_msg },
- { "modules", "Listing of all loaded kernel modules",
+ { "modules", "Kernel modules", "Listing of all loaded kernel modules",
linux_xfer_osdata_modules },
{ NULL, NULL, NULL }
};
@@ -1594,9 +1595,11 @@ linux_common_xfer_osdata (const char *annex, gdb_byte *readbuf,
"<item>"
"<column name=\"Type\">%s</column>"
"<column name=\"Description\">%s</column>"
+ "<column name=\"Title\">%s</column>"
"</item>",
osdata_table[i].type,
- osdata_table[i].description);
+ osdata_table[i].description,
+ osdata_table[i].title);
buffer_grow_str0 (&buffer, "</osdata>\n");
buf = buffer_finish (&buffer);