fixed borland warning

This commit is contained in:
Jeff Hill
2001-01-22 23:00:13 +00:00
parent 57bf87beac
commit abe1bc9e98
6 changed files with 52 additions and 25 deletions

34
src/ca/comBuf.cpp Normal file
View File

@@ -0,0 +1,34 @@
/*
* $Id$
*
*
* L O S A L A M O S
* Los Alamos National Laboratory
* Los Alamos, New Mexico 87545
*
* Copyright, 1986, The Regents of the University of California.
*
*
* Author Jeffrey O. Hill
* johill@lanl.gov
*/
#include "iocinf.h"
#include "comBuf_IL.h"
bool comBuf::flushToWire ( wireSendAdapter &wire )
{
unsigned occupied = this->occupiedBytes ();
while ( occupied ) {
unsigned nBytes = wire.sendBytes ( &this->buf[this->nextReadIndex],
occupied );
if ( nBytes == 0u ) {
this->nextReadIndex = this->nextWriteIndex;
return false;
}
this->nextReadIndex += nBytes;
occupied = this->occupiedBytes ();
}
return true;
}