Check-in Number:
|
4201 | |
Date: |
2001-Jul-16 20:31:36 (local)
2001-Jul-16 18:31:36 (UTC) |
User: | simons |
Branch: | |
Comment: |
We need to make a difference between the callback using up all buffer
capacity, in which case we need to enlarge the buffer but don't need
to restart the callback, and the callback truncating its output,
because the buffer was too small, in which case we need to enlarge the
buffer and restart the callback. |
Tickets: |
|
Inspections: |
|
Files: |
|
ossp-pkg/xds/vencode.c 1.6 -> 1.7
--- vencode.c 2001/07/16 18:28:32 1.6
+++ vencode.c 2001/07/16 18:31:36 1.7
@@ -122,6 +122,11 @@
{ /* enlarge buffer */
int rc2;
+ if (rc > xds->buffer_capacity - xds->buffer_len)
+ restart_engine = (1==1);
+ else
+ restart_engine = (1!=1);
+
if (!xds->we_own_buffer)
{
rc = XDS_ERR_OVERFLOW;
@@ -139,7 +144,6 @@
rc = rc2;
goto leave;
}
- restart_engine = (1==1);
printf("Enlarged buffer to %d byte.\n", xds->buffer_capacity);
}
else
|
|