[vlc-devel] [PATCH] cachegen: SetErrorMode is not available on Winstore 8.1

Rémi Denis-Courmont remi at remlab.net
Wed Oct 25 18:15:46 CEST 2017


Le keskiviikkona 25. lokakuuta 2017, 8.55.49 EEST Steve Lhomme a écrit :
> On Tue, Oct 24, 2017 at 6:20 PM, Rémi Denis-Courmont <remi at remlab.net> 
wrote:
> > Le tiistaina 24. lokakuuta 2017, 17.44.53 EEST Steve Lhomme a écrit :
> >> On Tue, Oct 24, 2017 at 5:28 PM, Rémi Denis-Courmont <remi at remlab.net>
> > 
> > wrote:
> >> > Le tiistaina 24. lokakuuta 2017, 13.58.34 EEST Steve Lhomme a écrit :
> >> >> ---
> >> >> 
> >> >>  bin/cachegen.c | 2 +-
> >> >>  1 file changed, 1 insertion(+), 1 deletion(-)
> >> >> 
> >> >> diff --git a/bin/cachegen.c b/bin/cachegen.c
> >> >> index 0e52559aaa..2368a7b05e 100644
> >> >> --- a/bin/cachegen.c
> >> >> +++ b/bin/cachegen.c
> >> >> @@ -48,7 +48,7 @@ static void usage (const char *path)
> >> >> 
> >> >>  int main (int argc, char *argv[])
> >> >>  {
> >> >> 
> >> >> -#ifdef _WIN32
> >> >> +#if defined(_WIN32) && (!VLC_WINSTORE_APP || _WIN32_WINNT >= 0x0A00)
> >> >> 
> >> >>      SetErrorMode(SEM_FAILCRITICALERRORS);
> >> >>  
> >> >>  #endif
> >> >>  #ifdef HAVE_GETOPT_H
> >> > 
> >> > VLC only needs SetErrorMode() on Windows 2008 and older so this makes
> >> > no
> >> > sense.
> >> 
> >> Windows 8.1 > 2008 but the API is not available for Winstore apps on
> >> Windows 8.1.
> > 
> > Yes, this patch makes no sense.
> 
> Maybe you don't understand it. But it is correct. This API is
> available on all targets we support except for Winstore on 8.1
> (Winstore on 10 is fine).

Indeed, I do not understand how it makes sense to call a function only on 
Windows 8.1 and later, when the function call is only useful on Windows 6 and 
earlier.

-- 
雷米‧德尼-库尔蒙
https://www.remlab.net/



More information about the vlc-devel mailing list