sapling/eden/fs/utils
Xavier Deguillard 6dd4d77e88 utils: properly detect ENOENT on Windows
Summary:
On Windows, system error may be using the Win32ErrorCategory, and not the
generic system_category or generic_category. Thus we also need to test for that
category as well as the Windows error codes.

Reading a bit on the internet how Win32 error codes are supposed to be handled,
in theory, using the system_category should be the preferred method. However,
this would also mean that printing exceptions would also contain a \r at the
end, which feels suboptimal. Maybe xlog should just be fixed to never try to
print \r characters to avoid this issue?

Reviewed By: genevievehelsel

Differential Revision: D37189378

fbshipit-source-id: 03ca35c38a05bc35c8a184a6069b1ab41b6852c0
2022-06-16 15:57:28 -07:00
..
test pathmap: fix case sensitivity insertion ordering 2022-05-19 18:57:33 -07:00
BucketedLog.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
BufVec.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Bug.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Bug.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
CaseSensitivity.h fs: fix license header 2022-01-04 15:00:07 -08:00
ChronoParse.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ChronoParse.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ChronoUnit.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ChronoUnit.gperf fs: fix license header 2022-01-04 15:00:07 -08:00
ChronoUnit.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Clock.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Clock.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
CMakeLists.txt move handle 2022-04-04 11:37:38 -07:00
CoverageSet.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
CoverageSet.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
DirType.cpp fs: fix license header 2022-01-04 15:00:07 -08:00
DirType.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
EdenError.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
EdenError.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
EdenTaskQueue.cpp fs: fix license header 2022-01-04 15:00:07 -08:00
EdenTaskQueue.h fs: fix license header 2022-01-04 15:00:07 -08:00
EnumValue.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
FaultInjector.cpp use F14NodeMap in FaultInjector 2022-05-17 13:38:33 -07:00
FaultInjector.h add FaultInjector::check() methods that dynamically construct the key 2022-05-18 20:12:47 -07:00
FileDescriptor.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
FileDescriptor.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
FileHash.cpp move win error 2022-04-04 11:37:38 -07:00
FileHash.h fs: fix license header 2022-01-04 15:00:07 -08:00
FileUtils.cpp move handle 2022-04-04 11:37:38 -07:00
FileUtils.h utils: add a getAllDirectoryEntryNames function 2022-03-23 13:59:52 -07:00
FsChannelTypes.h fs: fix license header 2022-01-04 15:00:07 -08:00
Future.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
FutureUnixSocket.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
FutureUnixSocket.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Guid.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
IDGen.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
IDGen.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ImmediateFuture-inl.h fix invalidation on NFS 2022-04-19 20:32:54 -07:00
ImmediateFuture-pre.h fs: fix license header 2022-01-04 15:00:07 -08:00
ImmediateFuture.h fix invalidation on NFS 2022-04-19 20:32:54 -07:00
IoFuture.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
IoFuture.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
LazyInitialize.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
LeaseCache.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
MappedDiskVector.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Memory.cpp fs: fix license header 2022-01-04 15:00:07 -08:00
Memory.h fs: fix license header 2022-01-04 15:00:07 -08:00
NfsSocket.cpp fs: fix license header 2022-01-04 15:00:07 -08:00
NfsSocket.h fs: fix license header 2022-01-04 15:00:07 -08:00
NotImplemented.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
PathFuncs.cpp pathmap: fix case sensitivity insertion ordering 2022-05-19 18:57:33 -07:00
PathFuncs.h pathmap: fix case sensitivity insertion ordering 2022-05-19 18:57:33 -07:00
PathMap.h pathmap: fix case sensitivity insertion ordering 2022-05-19 18:57:33 -07:00
Pipe.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Pipe.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ProcessAccessLog.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ProcessAccessLog.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
ProcUtil.cpp fs: fix license header 2022-01-04 15:00:07 -08:00
ProcUtil.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
SortedInsert.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
SpawnedProcess.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
SpawnedProcess.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
SSLContext.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
SSLContext.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
StaticAssert.h fs: fix license header 2022-01-04 15:00:07 -08:00
StatTimes.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
SystemError.h utils: properly detect ENOENT on Windows 2022-06-16 15:57:28 -07:00
Thread.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Thread.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
TimeUtil.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
TimeUtil.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
UnboundedQueueExecutor.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
UnboundedQueueExecutor.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
UnixSocket.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
UnixSocket.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
UserInfo.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
UserInfo.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Utf8.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
Utf8.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
WinStackTrace.cpp windows: teach eden to look for pdb in the binary path 2022-05-03 13:39:24 -07:00
WinStackTrace.h windows: teach eden to look for pdb in the binary path 2022-05-03 13:39:24 -07:00
XAttr.cpp standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00
XAttr.h standardize namespaces on C++17 syntax 2022-05-17 10:12:56 -07:00