Add a ring buffer to debugging + other things
[spider.git] / cmd / show / debug_ring.pl
diff --git a/cmd/show/debug_ring.pl b/cmd/show/debug_ring.pl
new file mode 100644 (file)
index 0000000..9a2eb01
--- /dev/null
@@ -0,0 +1,13 @@
+#
+# Log the current values of the DXDebug dbgring butter
+#
+#
+#
+my $self = shift;
+my $line = shift;;
+return (1, $self->msg('e5')) unless $self->priv >= 9;
+
+DXDebug::dbgprintring();
+DXDebug::dbgclearring() if $line =~ /^clear$/;
+
+return (1, 'Contents of debug ring buffer logged. View with watchdbg.');