902 static void
903 check_fd_limit()
904 {
905 int fds_throttle = -1;
906 REC_ReadConfigInteger(fds_throttle, "proxy.config.net.connections_throttle");
907 if (fds_throttle > fds_limit + THROTTLE_FD_HEADROOM) { 908 int new_fds_throttle = fds_limit - THROTTLE_FD_HEADROOM;
909 if (new_fds_throttle < 1) {
910 ink_abort("too few file descriptors (%d) available", fds_limit);
911 }
912 char msg[256];
913 snprintf(msg, sizeof(msg), "connection throttle too high, "
914 "%d (throttle) + %d (internal use) > %d (file descriptor limit), "
915 "using throttle of %d",
916 fds_throttle, THROTTLE_FD_HEADROOM, fds_limit, new_fds_throttle);
917 SignalWarning(MGMT_SIGNAL_SYSTEM_ERROR, msg);
918 }
919 }