rtsp: Don't use a locale dependent format string

Message ID 1300868782-57340-1-git-send-email-martin@martin.st
State Committed
Commit 28e9c42afbf0088aa1f4280a95d304dca4b675a0
Headers show

Commit Message

Martin Storsjö March 23, 2011, 8:26 a.m.
In this particular case, we aren't ever printing anything else than
0.000 anyway.
---
 libavformat/rtspenc.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

Comments

Luca Barbato March 23, 2011, 9:36 a.m. | #1
On 03/23/2011 09:26 AM, Martin Storsjö wrote:
> In this particular case, we aren't ever printing anything else than
> 0.000 anyway.

Patch ok =)
Ronald Bultje March 23, 2011, 11:18 a.m. | #2
Hi,

On Wed, Mar 23, 2011 at 5:36 AM, Luca Barbato <lu_zero@gentoo.org> wrote:
> On 03/23/2011 09:26 AM, Martin Storsjö wrote:
>> In this particular case, we aren't ever printing anything else than
>> 0.000 anyway.
>
> Patch ok =)

Queued.

Ronald

Patch

diff --git a/libavformat/rtspenc.c b/libavformat/rtspenc.c
index c163f4c..1f1fd32 100644
--- a/libavformat/rtspenc.c
+++ b/libavformat/rtspenc.c
@@ -103,8 +103,7 @@  static int rtsp_write_record(AVFormatContext *s)
     char cmd[1024];
 
     snprintf(cmd, sizeof(cmd),
-             "Range: npt=%0.3f-\r\n",
-             (double) 0);
+             "Range: npt=0.000-\r\n");
     ff_rtsp_send_cmd(s, "RECORD", rt->control_uri, cmd, reply, NULL);
     if (reply->status_code != RTSP_STATUS_OK)
         return -1;