diff options
author | dimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7> | 2012-09-30 13:51:29 (GMT) |
---|---|---|
committer | dimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7> | 2012-09-30 13:51:29 (GMT) |
commit | 9c9313827b29876de43ad5305fd7ac162013359c (patch) | |
tree | d18c06222e0f84d6077b586e5633053a8bc09da8 /src/store.cpp | |
parent | 489cefdf7a2ce294a15cb12b866dce13f5664f12 (diff) | |
download | Doxygen-9c9313827b29876de43ad5305fd7ac162013359c.zip Doxygen-9c9313827b29876de43ad5305fd7ac162013359c.tar.gz Doxygen-9c9313827b29876de43ad5305fd7ac162013359c.tar.bz2 |
Release-1.8.2-20120930
Diffstat (limited to 'src/store.cpp')
-rw-r--r-- | src/store.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/store.cpp b/src/store.cpp index 6d3b7d1..74719a9 100644 --- a/src/store.cpp +++ b/src/store.cpp @@ -162,7 +162,7 @@ int Store::write(const char *buf,uint size) #else portable_off_t curPos = m_cur; #endif - int bytesInBlock = BLOCK_SIZE - BLOCK_POINTER_SIZE - (curPos & (BLOCK_SIZE-1)); + int bytesInBlock = (int)(BLOCK_SIZE - BLOCK_POINTER_SIZE - (curPos & (BLOCK_SIZE-1))); int bytesLeft = bytesInBlock<(int)size ? (int)size-bytesInBlock : 0; int numBytes = size - bytesLeft; STORE_ASSERT(bytesInBlock>=0); @@ -254,7 +254,7 @@ void Store::end() #else portable_off_t curPos = m_cur; #endif - int bytesInBlock = BLOCK_SIZE - (curPos & (BLOCK_SIZE-1)); + int bytesInBlock = (int)(BLOCK_SIZE - (curPos & (BLOCK_SIZE-1))); //printf("%x: Store::end erasing %x bytes\n",(int)curPos&~(BLOCK_SIZE-1),bytesInBlock); //printf("end: bytesInBlock=%x\n",bytesInBlock); // zero out rest of the block @@ -327,7 +327,7 @@ int Store::read(char *buf,uint size) #else portable_off_t curPos = m_cur; #endif - int bytesInBlock = BLOCK_SIZE - BLOCK_POINTER_SIZE - (curPos & (BLOCK_SIZE-1)); + int bytesInBlock = (int)(BLOCK_SIZE - BLOCK_POINTER_SIZE - (curPos & (BLOCK_SIZE-1))); int bytesLeft = bytesInBlock<(int)size ? (int)size-bytesInBlock : 0; int numBytes = size - bytesLeft; //printf(" Store::read: pos=%x num=%d left=%d\n",(int)curPos,numBytes,bytesLeft); |