How do I make libavformat reconnect when connection is reset by peer? I am opening a network file via HTTPS like this: