[−][src]Function transmission_sys::tr_torrentParse
pub unsafe extern "C" fn tr_torrentParse(
ctor: *const tr_ctor,
setme_info_or_NULL: *mut tr_info
) -> tr_parse_result
@brief Parses the specified metainfo
@return TR_PARSE_ERR if parsing failed; TR_PARSE_OK if parsing succeeded and it's not a duplicate; TR_PARSE_DUPLICATE if parsing succeeded but it's a duplicate.
@param setme_info_or_NULL If parsing is successful and setme_info is non-NULL, the parsed metainfo is stored there and sould be freed by calling tr_metainfoFree() when no longer needed.
Notes:
-
tr_torrentParse() won't be able to check for duplicates -- and therefore won't return TR_PARSE_DUPLICATE -- unless ctor's "download-dir" and session variable is set.
-
setme_info->torrent's value can't be set unless ctor's session variable is set.