[vlc-devel] [PATCH] dsm: add missing I/O error handling
Janboe Ye
janboe.ye at outlook.com
Fri Feb 28 12:23:40 CET 2020
hi, Thomas
Is this patch ok for merge? Do I need to do anything else?
BTW, I created a pull request for libdsm to fix sigal issue, and there is no response for a week.
https://github.com/videolabs/libdsm/pull/142 <https://github.com/videolabs/libdsm/pull/142>
Could you also help to check?
Thanks a lot!
Janboe
> 2020年2月24日 下午5:06,Thomas Guillem <thomas at gllm.fr> 写道:
>
>
> On Mon, Feb 24, 2020, at 10:03, Rémi Denis-Courmont wrote:
>> -1 means EAGAIN and 0 means EOF here. Fatal errors should return zero (and write to log).
>
> Ah es, as explained by the stream documentation. I forgot about it.
>
> So LGTM.
>
>>
>> Though I don't know if DSM guarantees proper errno values.
>>
>> Le 24 février 2020 10:46:51 GMT+02:00, Thomas Guillem <thomas at gllm.fr> a écrit :
>>
>>
>> On Fri, Feb 21, 2020, at 21:04, Janboe Ye wrote:
>> From 7bba85e4f3a01b5afaa624e52c7534580f840f77 Mon Sep 17 00:00:00 2001
>> From: Janboe Ye <janboe.ye at outlook.com>
>> Date: Sat, 22 Feb 2020 04:00:39 +0800
>> Subject: [PATCH] dsm: add missing I/O error handling
>>
>> Signed-off-by: Janboe Ye <janboe.ye at outlook.com>
>> modules/access/dsm/access.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/modules/access/dsm/access.c b/modules/access/dsm/access.c
>> index 69f61b9860..795872092e 100644
>> --- a/modules/access/dsm/access.c
>> +++ b/modules/access/dsm/access.c
>> @@ -523,6 +523,8 @@ static ssize_t Read( stream_t *p_access, void
>> *p_buffer, size_t i_len )
>> if( i_read < 0 )
>> {
>> msg_Err( p_access, "read failed" );
>> + if (errno != EINTR && errno != EAGAIN)
>>
>> It is not the contrary ?
>> EINTR or EAGAIN should not be treated as error, right ?
>>
>> + return 0;
>> return -1;
>> }
>>
>> --
>> 2.23.0
>> vlc-devel mailing list
>> To unsubscribe or modify your subscription options:
>> https://mailman.videolan.org/listinfo/vlc-devel <https://mailman.videolan.org/listinfo/vlc-devel>
>> vlc-devel mailing list
>> To unsubscribe or modify your subscription options:
>> https://mailman.videolan.org/listinfo/vlc-devel <https://mailman.videolan.org/listinfo/vlc-devel>
>>
>> --
>> Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.
>> _______________________________________________
>> vlc-devel mailing list
>> To unsubscribe or modify your subscription options:
>> https://mailman.videolan.org/listinfo/vlc-devel <https://mailman.videolan.org/listinfo/vlc-devel>
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel <https://mailman.videolan.org/listinfo/vlc-devel>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20200228/fe10ea75/attachment.html>
More information about the vlc-devel
mailing list