Commit 2805b4ba authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

rand: ASCII path, use utf8_open for close-on-exec

parent 25e2a7e8
...@@ -35,6 +35,7 @@ ...@@ -35,6 +35,7 @@
#include <fcntl.h> #include <fcntl.h>
#include <unistd.h> #include <unistd.h>
#include <pthread.h> #include <pthread.h>
#include <vlc_charset.h>
#include <vlc_md5.h> #include <vlc_md5.h>
...@@ -57,7 +58,7 @@ static void vlc_rand_init (void) ...@@ -57,7 +58,7 @@ static void vlc_rand_init (void)
uint8_t key[BLOCK_SIZE]; uint8_t key[BLOCK_SIZE];
/* Get non-predictible value as key for HMAC */ /* Get non-predictible value as key for HMAC */
int fd = open (randfile, O_RDONLY); int fd = utf8_open (randfile, O_RDONLY);
if (fd == -1) if (fd == -1)
return; /* Uho! */ return; /* Uho! */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment