Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: Re: Patch: 3.1.6-bart-7: Another rlimit



On Oct 19,  5:22am, Bart Schaefer wrote:
} Subject: Patch: 3.1.6-bart-7: Another rlimit
}
}      RLIMIT_PTHREAD   The maximum number of threads (pthreads(5))

The "ulimit -a" command should report this; same for "sockbufsize".

Index: Src/Builtins/rlimits.c
===================================================================
@@ -232,6 +232,20 @@
 	    limit /= 1024;
 	break;
 # endif /* RLIMIT_AIO_MEM */
+# ifdef RLIMIT_SBSIZE
+    case RLIMIT_SBSIZE:
+	if (head)
+	    printf("socket buffer size (kb)    ");
+	if (limit != RLIM_INFINITY)
+	    limit /= 1024;
+	break;
+# endif /* RLIMIT_SBSIZE */
+# ifdef RLIMIT_PTHREAD
+    case RLIMIT_PTHREAD:
+	if (head)
+	    printf("threads per process        ");
+	break;
+# endif /* RLIMIT_PTHREAD */
     }
     /* display the limit */
     if (limit == RLIM_INFINITY)

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



Messages sorted by: Reverse Date, Date, Thread, Author