I am (seemingly) randomly getting the error:
"Insufficient system resources exist to complete the requested service"
When using the boost::asio::async_read_until or boost::asio::async_write with a serial port.
Having the serial port declared as:
boost::asio::serial_port mSerialPort;
Following this error, I try to
try
{
mSerialPort.cancel();
mSerialPort.close();
}
catch(boost::system::system_error error)
{
;
}
Where one of them (not certain yet which) hangs and never returns, not even throwing an exception.
In general, what does this error mean ?
Has anybody encountered this problem ? Any direction in particular I should investigate ?
EDIT:
The serial port in question uses a USB emulator.
In regards to this other SO Question, specially the comment from Hans Passant, is it possible that this error is linked to the device driver ? I use the same code with another hardware component and never got this behavior.
EDIT 2:
When searching on the web for this particular error message, often it is recommended to increase the paged pool memory as described here:
Any sense in doing this in my case ?