static int file_move(URLContext *h_src, URLContext *h_dst)
{
-#if HAVE_UNISTD_H
const char *filename_src = h_src->filename;
const char *filename_dst = h_dst->filename;
av_strstart(filename_src, "file:", &filename_src);
return AVERROR(errno);
return 0;
-#else
- return AVERROR(ENOSYS);
-#endif /* HAVE_UNISTD_H */
}
#if CONFIG_FILE_PROTOCOL
#endif /* HAVE_LSTAT */
}
-URLProtocol ff_file_protocol = {
+const URLProtocol ff_file_protocol = {
.name = "file",
.url_open = file_open,
.url_read = file_read,
.url_open_dir = file_open_dir,
.url_read_dir = file_read_dir,
.url_close_dir = file_close_dir,
- .default_whitelist = "file"
+ .default_whitelist = "file,crypto"
};
#endif /* CONFIG_FILE_PROTOCOL */
return 0;
}
-URLProtocol ff_pipe_protocol = {
+const URLProtocol ff_pipe_protocol = {
.name = "pipe",
.url_open = pipe_open,
.url_read = file_read,
.url_check = file_check,
.priv_data_size = sizeof(FileContext),
.priv_data_class = &pipe_class,
- .default_whitelist = "none"
+ .default_whitelist = "crypto"
};
#endif /* CONFIG_PIPE_PROTOCOL */