Causes for ENOMEM from ::popen()
问题 I have an application that mostly works, but am having one condition wherein the call to ::popen() gets an error with errno set to ENOMEM. The man page for ::popen() refers you to page for ::fork() which itself lists ENOMEM with this brief comment on Linux: The fork() function may fail if: ENOMEM Insufficient storage space is available. I am wondering if I am really running out of memory, or perhaps some other resource like file descriptors? Can fork() give ENOMEM for something other than