aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2010-07-26 23:12:48 +0000
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2010-07-26 23:12:48 +0000
commitea35e3c61eea83a55c4b947f46143e0eb8ac5dd4 (patch)
tree6b281c1ebd216995abdbdc39c4b2ecae7c071b53
parentc90c80ac28d7573429bf7d739eb78fad9d9b79ab (diff)
downloadffmpeg-ea35e3c61eea83a55c4b947f46143e0eb8ac5dd4.tar.gz
Avoid the use of an intermediary variable in
av_parse_video_rate(). Simplify. Originally committed as revision 24524 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavcore/parseutils.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/libavcore/parseutils.c b/libavcore/parseutils.c
index 9a87d07e98..e8ce6cfec7 100644
--- a/libavcore/parseutils.c
+++ b/libavcore/parseutils.c
@@ -139,9 +139,7 @@ int av_parse_video_rate(AVRational *rate, const char *arg)
rate->num = 0;
} else {
/* Finally we give up and parse it as double */
- AVRational time_base = av_d2q(strtod(arg, 0), 1001000);
- rate->den = time_base.den;
- rate->num = time_base.num;
+ *rate = av_d2q(strtod(arg, 0), 1001000);
}
if (rate->num <= 0 || rate->den <= 0)
return AVERROR(EINVAL);