Manually tweak source formatting and then re-run clang-format

This commit is contained in:
Yuri Kunde Schlesner
2016-09-18 18:01:46 -07:00
parent 784b96d87f
commit 396a8d91a4
169 changed files with 805 additions and 809 deletions

View File

@ -63,82 +63,84 @@ static const s32 SOCKET_ERROR_VALUE = -1;
namespace SOC_U {
/// Holds the translation from system network errors to 3DS network errors
static const std::unordered_map<int, int> error_map = {{{E2BIG, 1},
{ERRNO(EACCES), 2},
{ERRNO(EADDRINUSE), 3},
{ERRNO(EADDRNOTAVAIL), 4},
{ERRNO(EAFNOSUPPORT), 5},
{ERRNO(EAGAIN), 6},
{ERRNO(EALREADY), 7},
{ERRNO(EBADF), 8},
{EBADMSG, 9},
{EBUSY, 10},
{ECANCELED, 11},
{ECHILD, 12},
{ERRNO(ECONNABORTED), 13},
{ERRNO(ECONNREFUSED), 14},
{ERRNO(ECONNRESET), 15},
{EDEADLK, 16},
{ERRNO(EDESTADDRREQ), 17},
{EDOM, 18},
{ERRNO(EDQUOT), 19},
{EEXIST, 20},
{ERRNO(EFAULT), 21},
{EFBIG, 22},
{ERRNO(EHOSTUNREACH), 23},
{EIDRM, 24},
{EILSEQ, 25},
{ERRNO(EINPROGRESS), 26},
{ERRNO(EINTR), 27},
{ERRNO(EINVAL), 28},
{EIO, 29},
{ERRNO(EISCONN), 30},
{EISDIR, 31},
{ERRNO(ELOOP), 32},
{ERRNO(EMFILE), 33},
{EMLINK, 34},
{ERRNO(EMSGSIZE), 35},
{ERRNO(EMULTIHOP), 36},
{ERRNO(ENAMETOOLONG), 37},
{ERRNO(ENETDOWN), 38},
{ERRNO(ENETRESET), 39},
{ERRNO(ENETUNREACH), 40},
{ENFILE, 41},
{ERRNO(ENOBUFS), 42},
{ENODATA, 43},
{ENODEV, 44},
{ENOENT, 45},
{ENOEXEC, 46},
{ENOLCK, 47},
{ENOLINK, 48},
{ENOMEM, 49},
{ENOMSG, 50},
{ERRNO(ENOPROTOOPT), 51},
{ENOSPC, 52},
{ENOSR, 53},
{ENOSTR, 54},
{ENOSYS, 55},
{ERRNO(ENOTCONN), 56},
{ENOTDIR, 57},
{ERRNO(ENOTEMPTY), 58},
{ERRNO(ENOTSOCK), 59},
{ENOTSUP, 60},
{ENOTTY, 61},
{ENXIO, 62},
{ERRNO(EOPNOTSUPP), 63},
{EOVERFLOW, 64},
{EPERM, 65},
{EPIPE, 66},
{EPROTO, 67},
{ERRNO(EPROTONOSUPPORT), 68},
{ERRNO(EPROTOTYPE), 69},
{ERANGE, 70},
{EROFS, 71},
{ESPIPE, 72},
{ESRCH, 73},
{ERRNO(ESTALE), 74},
{ETIME, 75},
{ERRNO(ETIMEDOUT), 76}}};
static const std::unordered_map<int, int> error_map = {{
{E2BIG, 1},
{ERRNO(EACCES), 2},
{ERRNO(EADDRINUSE), 3},
{ERRNO(EADDRNOTAVAIL), 4},
{ERRNO(EAFNOSUPPORT), 5},
{ERRNO(EAGAIN), 6},
{ERRNO(EALREADY), 7},
{ERRNO(EBADF), 8},
{EBADMSG, 9},
{EBUSY, 10},
{ECANCELED, 11},
{ECHILD, 12},
{ERRNO(ECONNABORTED), 13},
{ERRNO(ECONNREFUSED), 14},
{ERRNO(ECONNRESET), 15},
{EDEADLK, 16},
{ERRNO(EDESTADDRREQ), 17},
{EDOM, 18},
{ERRNO(EDQUOT), 19},
{EEXIST, 20},
{ERRNO(EFAULT), 21},
{EFBIG, 22},
{ERRNO(EHOSTUNREACH), 23},
{EIDRM, 24},
{EILSEQ, 25},
{ERRNO(EINPROGRESS), 26},
{ERRNO(EINTR), 27},
{ERRNO(EINVAL), 28},
{EIO, 29},
{ERRNO(EISCONN), 30},
{EISDIR, 31},
{ERRNO(ELOOP), 32},
{ERRNO(EMFILE), 33},
{EMLINK, 34},
{ERRNO(EMSGSIZE), 35},
{ERRNO(EMULTIHOP), 36},
{ERRNO(ENAMETOOLONG), 37},
{ERRNO(ENETDOWN), 38},
{ERRNO(ENETRESET), 39},
{ERRNO(ENETUNREACH), 40},
{ENFILE, 41},
{ERRNO(ENOBUFS), 42},
{ENODATA, 43},
{ENODEV, 44},
{ENOENT, 45},
{ENOEXEC, 46},
{ENOLCK, 47},
{ENOLINK, 48},
{ENOMEM, 49},
{ENOMSG, 50},
{ERRNO(ENOPROTOOPT), 51},
{ENOSPC, 52},
{ENOSR, 53},
{ENOSTR, 54},
{ENOSYS, 55},
{ERRNO(ENOTCONN), 56},
{ENOTDIR, 57},
{ERRNO(ENOTEMPTY), 58},
{ERRNO(ENOTSOCK), 59},
{ENOTSUP, 60},
{ENOTTY, 61},
{ENXIO, 62},
{ERRNO(EOPNOTSUPP), 63},
{EOVERFLOW, 64},
{EPERM, 65},
{EPIPE, 66},
{EPROTO, 67},
{ERRNO(EPROTONOSUPPORT), 68},
{ERRNO(EPROTOTYPE), 69},
{ERANGE, 70},
{EROFS, 71},
{ESPIPE, 72},
{ESRCH, 73},
{ERRNO(ESTALE), 74},
{ETIME, 75},
{ERRNO(ETIMEDOUT), 76},
}};
/// Converts a network error from platform-specific to 3ds-specific
static int TranslateError(int error) {