r18049: Backport SAMBA_4_0 snprintf changes