Definition at line 448 of file lwprint.c.
449{
450 char *ptr, *totrim = NULL;
451 int len;
452 int i;
453
455
456 ptr = strchr(
str,
'.');
457 if (!ptr) return;
458
460
461 len = strlen(ptr);
462 for (i = len - 1; i; i--)
463 {
464 if (ptr[i] != '0') break;
465 totrim = &ptr[i];
466 }
467 if (totrim)
468 {
469 if (ptr == totrim - 1)
470 *ptr = '\0';
471 else
472 *totrim = '\0';
473 }
474
476}
#define LWDEBUGF(level, msg,...)
References LWDEBUGF, and str.
Referenced by lwprint_double().