diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2008-01-10 13:09:43 +0000 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2008-01-10 13:09:43 +0000 |
commit | fa859275c66afc639cd3d2ea8a74cfdc63be8b99 (patch) | |
tree | 81d3e957f53a7a8d5b4d973d693a026ae5d087ad /queue.c | |
parent | 8a861afefac51ab495e5ba7946fe4fd986f0dd3c (diff) | |
download | rsyslog-fa859275c66afc639cd3d2ea8a74cfdc63be8b99.tar.gz rsyslog-fa859275c66afc639cd3d2ea8a74cfdc63be8b99.tar.xz rsyslog-fa859275c66afc639cd3d2ea8a74cfdc63be8b99.zip |
- added write functions for several types to stream class
- changed objSerialize methods to work directly on the stream class
Diffstat (limited to 'queue.c')
-rw-r--r-- | queue.c | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -238,15 +238,16 @@ static rsRetVal qDestructDisk(queue_t *pThis) static rsRetVal qAddDisk(queue_t *pThis, void* pUsr) { DEFiRet; - rsCStrObj *pCStr; assert(pThis != NULL); - //CHKiRet(strmOpenFile(pThis->tVars.disk.pWrite, O_RDWR|O_CREAT|O_TRUNC, 0600)); // TODO: open modes! - + CHKiRet((objSerialize(pUsr))(pUsr, pThis->tVars.disk.pWrite)); + CHKiRet(strmFlush(pThis->tVars.disk.pWrite)); +#if 0 + //rsCStrObj *pCStr; CHKiRet((objSerialize(pUsr))(pUsr, &pCStr)); CHKiRet(strmWrite(pThis->tVars.disk.pWrite, rsCStrGetBufBeg(pCStr), rsCStrLen(pCStr))); - CHKiRet(strmFlush(pThis->tVars.disk.pWrite)); +#endif finalize_it: return iRet; |