ntdll: Assert when trying to replace an exiting file descriptor in fd_cache.

Alexandre Julliard julliard at winehq.org
Wed Mar 4 01:15:39 CST 2015

Sebastian Lackner <sebastian at fds-team.de> writes:

> The condition "prev_fd != -1" should never be true. If this is the case then something
> is going terrible wrong, and it is better to assert instead of just closing the file
> descriptor.

It can happen if the handle was closed on the server side but not yet
removed from the cache. Yes, handling of that case is not ideal, but an
assert is not an improvement.

Alexandre Julliard
julliard at winehq.org

More information about the wine-devel mailing list