Skip to content
Snippets Groups Projects
Commit 89dbb5c8 authored by Stephen R. van den Berg's avatar Stephen R. van den Berg
Browse files

pgsql: Accomodate for sscanf() using range_error(0).

parent e5da1bf6
Branches
Tags
No related merge requests found
......@@ -347,8 +347,12 @@ class conxiin {
protected final bool range_error(int howmuch) {
#ifdef PG_DEBUG
if (howmuch <= 0)
error("Out of range %d\n", howmuch);
if (howmuch < 0) {
int available = unread(0);
unread(available);
error("Out of range %d %O %O\n", howmuch,
((string)this)[.. available-1], ((string)this)[available ..]);
}
#endif
if (fillread) {
Thread.MutexKey lock = fillreadmux->lock();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment