X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=session_file.c;h=a928bb1240bc12df4706e9bff062043109e5609a;hb=0acdd79357633e90bb1a398e246ad96b39dceda9;hp=3ace85b628221cacdb8bbbf1b546c47f2acde746;hpb=f3ca73edd29a48f8cc19755df629ab2bc9478eea;p=libsigrok.git diff --git a/session_file.c b/session_file.c index 3ace85b6..a928bb12 100644 --- a/session_file.c +++ b/session_file.c @@ -30,7 +30,9 @@ #include "libsigrok.h" #include "libsigrok-internal.h" +/** @cond PRIVATE */ #define LOG_PREFIX "session-file" +/** @endcond */ /** * @file @@ -114,7 +116,7 @@ SR_API int sr_session_load(const char *filename) struct zip_stat zs; struct sr_dev_inst *sdi; struct sr_channel *ch; - int ret, channelnum, devcnt, i, j; + int devcnt, ret, i, j; uint64_t tmp_u64, total_channels, enabled_channels, p; char **sections, **keys, *metafile, *val; char channelname[SR_MAX_CHANNELNAME_LEN + 1]; @@ -198,9 +200,6 @@ SR_API int sr_session_load(const char *filename) tmp_u64 = strtoul(keys[j]+5, NULL, 10); /* sr_session_save() */ sr_dev_channel_name_set(sdi, tmp_u64 - 1, val); - } else if (!strncmp(keys[j], "trigger", 7)) { - channelnum = strtoul(keys[j]+7, NULL, 10); - sr_dev_trigger_set(sdi, channelnum, val); } } g_strfreev(keys); @@ -230,6 +229,8 @@ SR_API int sr_session_load(const char *filename) * @retval SR_OK Success * @retval SR_ERR_ARG Invalid arguments * @retval SR_ERR Other errors + * + * @since 0.2.0 */ SR_API int sr_session_save(const char *filename, const struct sr_dev_inst *sdi, unsigned char *buf, int unitsize, int units) @@ -284,6 +285,8 @@ SR_API int sr_session_save(const char *filename, const struct sr_dev_inst *sdi, * @retval SR_OK Success * @retval SR_ERR_ARG Invalid arguments * @retval SR_ERR Other errors + * + * @since 0.3.0 */ SR_API int sr_session_save_init(const char *filename, uint64_t samplerate, char **channels) @@ -375,6 +378,8 @@ SR_API int sr_session_save_init(const char *filename, uint64_t samplerate, * @retval SR_OK Success * @retval SR_ERR_ARG Invalid arguments * @retval SR_ERR Other errors + * + * @since 0.3.0 */ SR_API int sr_session_append(const char *filename, unsigned char *buf, int unitsize, int units)