message: Check `GDALGetRasterUnitType` for null ptr
diff: @@ -481,6 +481,11 @@ impl<'a> RasterBand<'a> {
  /// If there is no unit, the empty string is returned.
  pub fn unit(&self) -> String {
  let str_ptr = unsafe { gdal_sys::GDALGetRasterUnitType(self.c_rasterband) };
  +
  + if str_ptr.is_null() {
  + return String::new();
  + }
  +
  _string(str_ptr)
  }
  }
  