From 5da1313be24d27eef6103a478f75345723e65614 Mon Sep 17 00:00:00 2001 From: Jan Kratochvil Date: Sat, 7 Aug 2010 15:00:39 +0000 Subject: gdb/ * defs.h (make_cleanup_restore_uinteger, make_cleanup_restore_ui_file) (make_cleanup_restore_page_info) (set_batch_flag_and_make_cleanup_restore_page_info): New declarations. * gdbcmd.h (execute_command_to_string): New declaration. * python/python.c (struct restore_ui_file_closure, restore_ui_file) (make_cleanup_restore_ui_file): Move to utils.c (execute_gdb_command) : Move ... * top.c (execute_command_to_string): ... here. Call set_batch_flag_and_make_cleanup_restore_page_info. * utils.c (make_cleanup_restore_integer): New source file blank line. (make_cleanup_restore_uinteger): New. (struct restore_ui_file_closure, do_restore_ui_file) (make_cleanup_restore_ui_file): Move here from python/python.c. (init_page_info) (do_restore_page_info_cleanup, make_cleanup_restore_page_info) (set_batch_flag_and_make_cleanup_restore_page_info): New. gdb/testsuite/ * gdb.python/python.exp (show height, set height 10) (verify pagination beforehand, verify pagination beforehand: q) (gdb.execute does not page, verify pagination afterwards) (verify pagination afterwards: q): New. gdb/doc/ * gdb.texinfo (Mode Options) <-batch> (Basic Python) : Describe setting width and height. --- gdb/defs.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'gdb/defs.h') diff --git a/gdb/defs.h b/gdb/defs.h index c568a12..c7a5215 100644 --- a/gdb/defs.h +++ b/gdb/defs.h @@ -351,10 +351,14 @@ struct obstack; extern struct cleanup *make_cleanup_obstack_free (struct obstack *obstack); extern struct cleanup *make_cleanup_restore_integer (int *variable); +extern struct cleanup *make_cleanup_restore_uinteger (unsigned int *variable); struct target_ops; extern struct cleanup *make_cleanup_unpush_target (struct target_ops *ops); +extern struct cleanup * + make_cleanup_restore_ui_file (struct ui_file **variable); + extern struct cleanup *make_final_cleanup (make_cleanup_ftype *, void *); extern struct cleanup *make_my_cleanup (struct cleanup **, @@ -386,6 +390,10 @@ extern int yquery (const char *, ...) ATTRIBUTE_PRINTF (1, 2); extern void init_page_info (void); +extern struct cleanup *make_cleanup_restore_page_info (void); +extern struct cleanup * + set_batch_flag_and_make_cleanup_restore_page_info (void); + extern char *gdb_realpath (const char *); extern char *xfullpath (const char *); -- cgit v1.1