Logo Search packages:      
Sourcecode: libgphoto2 version File versions

int gp_log_remove_func ( int  id  ) 

Remove a logging receiving function.

Parameters:
id an id (return value of gp_log_add_func)
Removes the log function with given id.

Returns:
a gphoto2 error code

Definition at line 115 of file gphoto2-port-log.c.

References GP_ERROR_BAD_PARAMETERS, and GP_OK.

{
      if (id < 1 || id > log_funcs_count)
            return (GP_ERROR_BAD_PARAMETERS);

      memmove (log_funcs + id - 1, log_funcs + id, log_funcs_count - id);
      log_funcs_count--;

      return (GP_OK);
}


Generated by  Doxygen 1.6.0   Back to index