ws: Use right printf format for limiting string length

Closes #524
Reviewed-by: Marius Vollmer <marius.vollmer@redhat.com>