gdb/
authorJan Kratochvil <jan.kratochvil@redhat.com>
Sun, 5 May 2013 16:56:07 +0000 (16:56 +0000)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Sun, 5 May 2013 16:56:07 +0000 (16:56 +0000)
* cleanups.c (restore_my_cleanups): New gdb_assert for SENTINEL_CLEANUP.

gdb/ChangeLog
gdb/cleanups.c

index 75b205c9f9534bd2389bfade22b0513b4f4f390a..0bf36998fe225214c8abd0bc306a439eab449aad 100644 (file)
@@ -1,3 +1,7 @@
+2013-05-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+       * cleanups.c (restore_my_cleanups): New gdb_assert for SENTINEL_CLEANUP.
+
 2013-05-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        * event-top.c (display_gdb_prompt): Call missing do_cleanups.
index c403db7cc2deeefa56a489f661653688b506efda..02db9f5cddab413831b993405f9a97fd70bf63d8 100644 (file)
@@ -261,6 +261,7 @@ save_final_cleanups (void)
 static void
 restore_my_cleanups (struct cleanup **pmy_chain, struct cleanup *chain)
 {
+  gdb_assert (*pmy_chain == SENTINEL_CLEANUP);
   *pmy_chain = chain;
 }