In cl_msg_out() for the case of the message text being longer than allocated 
buffer, output the message once with a truncation warning message to follow.

signed-off-by: stan smith <[email protected]>

--- A/core/complib/user/cl_debug.c      Wed Jan 12 15:18:48 2011
+++ B/core/complib/user/cl_debug.c      Wed Jan 12 15:18:28 2011
@@ -53,9 +53,10 @@
                buffer[254] = '.';
                buffer[255] = '\0';
                OutputDebugStringA( buffer );
-               OutputDebugStringA( "WARNING: Buffer truncated." );
+               OutputDebugStringA( "WARNING: cl_msg_out() previous message 
truncated.\n" );
        }
-       OutputDebugStringA( buffer );
+       else
+               OutputDebugStringA( buffer );
        va_end(args);
 }

_______________________________________________
ofw mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ofw

Reply via email to