1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-22 07:42:37 +00:00

fix: check tr_num_parse result in daemon (#7181)

This commit is contained in:
Yat Ho 2024-10-21 12:52:52 +08:00 committed by GitHub
parent a8bf44eeb1
commit 819d7f4136
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -603,7 +603,7 @@ bool tr_daemon::parse_args(int argc, char const* const* argv, bool* dump_setting
break;
case 953:
if (auto const ratio_limit = tr_num_parse<double>(optstr); optstr)
if (auto const ratio_limit = tr_num_parse<double>(optstr); ratio_limit)
{
tr_variantDictAddReal(&settings_, TR_KEY_ratio_limit, *ratio_limit);
}