Re: [PATCH 1/2]: Refactor relocate_path to also check if the relocated file/directory exists

Eli Zaretskii
2012-09-21T18:36:03Z

> Date: Fri, 21 Sep 2012 20:26:37 +0200
> From: Jan Kratochvil <jan.kratochvil@redhat.com>
> Cc: GDB Patches <gdb-patches@sourceware.org>
>
> if (stat (path, &s) != 0 || (isdir && !S_ISDIR (s.st_mode))
> || (!isdir && S_ISDIR (s.st_mode)))

a.k.a.

if (stat (path, &s) != 0 || isdir != S_ISDIR (s.st_mode))