Definition at line 99 of file ProfParse.cc.
bool Reader::nextSample |
( |
VoidVec & |
vv | ) |
|
Definition at line 108 of file ProfParse.cc.
References dtNoiseDBValidation_cfg::cerr, fd_, and SiPixelLorentzAngle_cfi::read.
Referenced by writeProfileData().
111 int sz =
read(
fd_,&cnt,
sizeof(
unsigned int));
114 perror(
"Reader::nextSample: read count");
115 std::cerr <<
"could not read next sample from profile data\n";
118 if(sz == 0)
return false;
119 if((
unsigned)sz<
sizeof(
unsigned int)) {
121 <<
"could not read the correct amount of profile data\n";
125 std::cerr <<
"Reader::nextSample: stack length is nonsense " << cnt <<
"\n";
131 int byte_cnt = cnt*
sizeof(
void*);
133 while((sz =
read(
fd_,pos,byte_cnt)) < byte_cnt) {
135 perror(
"Reader::nextSample: read stack");