| Index: net/base/net_errors_posix.cc
|
| diff --git a/net/base/net_errors_posix.cc b/net/base/net_errors_posix.cc
|
| index 143912cd5dd51e8bc06075c0f3241589487d09d0..0d8b7de34471895bca3d3ec527e70e4e01130475 100644
|
| --- a/net/base/net_errors_posix.cc
|
| +++ b/net/base/net_errors_posix.cc
|
| @@ -5,12 +5,19 @@
|
| #include "net/base/net_errors.h"
|
|
|
| #include <errno.h>
|
| +#include <stdlib.h>
|
| +#include <string>
|
| +#include <unistd.h>
|
|
|
| #include "base/logging.h"
|
| +#include "base/stringprintf.h"
|
|
|
| namespace net {
|
|
|
| Error MapSystemError(int os_error) {
|
| + if (os_error != 0)
|
| + DVLOG(2) << "Error " << os_error;
|
| +
|
| // There are numerous posix error codes, but these are the ones we thus far
|
| // find interesting.
|
| switch (os_error) {
|
| @@ -98,6 +105,8 @@ Error MapSystemError(int os_error) {
|
| return ERR_ACCESS_DENIED;
|
| case EUSERS: // Too many users.
|
| return ERR_INSUFFICIENT_RESOURCES;
|
| + case EMFILE: // Too many open files.
|
| + return ERR_INSUFFICIENT_RESOURCES;
|
|
|
| case 0:
|
| return OK;
|
|
|