Fix possible NULL argument to printf