Fixed wrong buffer length (added place for terminating zero)