mirror of
https://github.com/ceph/ceph
synced 2024-12-18 09:25:49 +00:00
common/MemoryModel: remove logging to /tmp/memlog
This was a hack for dev purposes ages ago; remove it. The predictable filename is a security issue. CVE-2013-1882 Reported-by: Michael Scherer <misc@zarb.org> Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Dan Mick <dan.mick@inktank.com>
This commit is contained in:
parent
6a7ad2eac1
commit
c524e2e01d
@ -97,19 +97,7 @@ void MemoryModel::_sample(snap *psnap)
|
||||
|
||||
psnap->malloc = mi.uordblks >> 10;
|
||||
psnap->mmap = mi.hblks >> 10;
|
||||
|
||||
|
||||
ofstream log("/tmp/memlog", ios::app);
|
||||
log << "heap " << heap
|
||||
<< "\trss " << psnap->rss
|
||||
<< "\tmi\t" << mi.arena
|
||||
<< "\t" << mi.ordblks
|
||||
<< "\t" << mi.uordblks / 1024
|
||||
<< "\t" << mi.fordblks / 1024
|
||||
<< "\t" << mi.hblks
|
||||
<< "\t" << mi.hblkhd / 1024
|
||||
<< std::endl;
|
||||
#else
|
||||
#warning "Not implemented!"
|
||||
#warning "mallinfo not implemented"
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user