if( Width > 0 )
{
// 4 preceding, 5 price
- int nameWidth = Width - 4 - 4 - snprintf(NULL, 0, "%i", price/100);
+ int nameWidth = Width - 4 - snprintf(NULL, 0, " %4i", price);
move( Row, Col );
if( Index >= 0 )
printw("%-*.*s", nameWidth, nameWidth, name);
- printw(" %i.%02i", price/100, price%100);
+ printw(" %4i", price);
}
else
{
if( newline ) {
int newLen = newline - (buf+bufPos) + 1;
bufValid = len - newLen;
- bufPos += newLen;
+ len = newLen;
}
if( len + bufPos == BUFSIZ - 1 ) bufPos = 0;
+ else bufPos += len;
}
#if DEBUG_TRACE_SERVER