mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: UIPstream when reaches eof deletes the underlying buffer.
Only in PstreamBuffers mode. This makes sure that data from other processors already handled gets deleted.
This commit is contained in:
@ -38,6 +38,7 @@ Foam::UIPstream::UIPstream
|
||||
DynamicList<char>& externalBuf,
|
||||
label& externalBufPosition,
|
||||
const int tag,
|
||||
const bool clearAtEnd,
|
||||
streamFormat format,
|
||||
versionNumber version
|
||||
)
|
||||
@ -48,6 +49,7 @@ Foam::UIPstream::UIPstream
|
||||
externalBuf_(externalBuf),
|
||||
externalBufPosition_(externalBufPosition),
|
||||
tag_(tag),
|
||||
clearAtEnd_(clearAtEnd),
|
||||
messageSize_(0)
|
||||
{
|
||||
notImplemented
|
||||
@ -59,6 +61,7 @@ Foam::UIPstream::UIPstream
|
||||
"DynamicList<char>&,"
|
||||
"label&,"
|
||||
"const int tag,"
|
||||
"const bool,"
|
||||
"streamFormat, versionNumber"
|
||||
")"
|
||||
);
|
||||
|
||||
@ -42,6 +42,7 @@ Foam::UIPstream::UIPstream
|
||||
DynamicList<char>& externalBuf,
|
||||
label& externalBufPosition,
|
||||
const int tag,
|
||||
const bool clearAtEnd,
|
||||
streamFormat format,
|
||||
versionNumber version
|
||||
)
|
||||
@ -52,6 +53,7 @@ Foam::UIPstream::UIPstream
|
||||
externalBuf_(externalBuf),
|
||||
externalBufPosition_(externalBufPosition),
|
||||
tag_(tag),
|
||||
clearAtEnd_(clearAtEnd),
|
||||
messageSize_(0)
|
||||
{
|
||||
setOpened();
|
||||
@ -125,6 +127,7 @@ Foam::UIPstream::UIPstream(const int fromProcNo, PstreamBuffers& buffers)
|
||||
externalBuf_(buffers.recvBuf_[fromProcNo]),
|
||||
externalBufPosition_(buffers.recvBufPos_[fromProcNo]),
|
||||
tag_(buffers.tag_),
|
||||
clearAtEnd_(true),
|
||||
messageSize_(0)
|
||||
{
|
||||
if (commsType() != UPstream::scheduled && !buffers.finishedSendsCalled_)
|
||||
|
||||
Reference in New Issue
Block a user