Logo Search packages:      
Sourcecode: libgphoto2 version File versions

int gp_file_unref ( CameraFile file  ) 

Decrease reference counter for CameraFile object.

Parameters:
file a CameraFile
Returns:
a gphoto2 error code.

Definition at line 167 of file gphoto2-file.c.

References CHECK_NULL, CHECK_RESULT, gp_file_free(), and GP_OK.

Referenced by gp_camera_file_get_info(), gp_filesystem_get_file(), and gp_filesystem_set_file_noop().

{
      CHECK_NULL (file);
      
      file->ref_count -= 1;

      if (file->ref_count == 0)
            CHECK_RESULT (gp_file_free (file));

      return (GP_OK);
}


Generated by  Doxygen 1.6.0   Back to index