OSDN Git Service

tgsi: correct handling of return value from util_vsnprintf
authorKeith Whitwell <keithw@vmware.com>
Fri, 26 Jun 2009 12:43:10 +0000 (13:43 +0100)
committerKeith Whitwell <keithw@vmware.com>
Fri, 26 Jun 2009 12:43:10 +0000 (13:43 +0100)
commit0cce6d7e337ac3de515c48d6077c823c32e22613
tree430571703bfa7cd8859aad26e915a2c81b56b6fc
parent0952645fe04a27968565ea4d913500c23b1b11e3
tgsi: correct handling of return value from util_vsnprintf

We were failing to deal with:
  - vsnprintf returns negative value on error.
  - vsnprintf returns the number of chars that *would* have been
    written on truncation.
src/gallium/auxiliary/tgsi/tgsi_dump.c