~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/pbms/src/system_table_ms.cc

  • Committer: Monty Taylor
  • Date: 2011-03-11 18:48:55 UTC
  • mfrom: (2228.1.8 build)
  • Revision ID: mordred@inaugust.com-20110311184855-1essd3a6xfr7lx6r
Merged Andrew: drizzledump and docs bug fixes
Merged Barry: pbms bugfixes

Show diffs side-by-side

added added

removed removed

Lines of Context:
855
855
 
856
856
 
857
857
//-----------------------
858
 
void MSRepositoryTable::seqScanPos(uint8_t *pos)
 
858
void MSRepositoryTable::seqScanPos(unsigned char *pos)
859
859
{
860
860
        mi_int4store(pos, iRepoIndex); pos +=4;
861
861
        mi_int8store(pos, iRepoCurrentOffset);
873
873
}
874
874
 
875
875
//-----------------------
876
 
void MSRepositoryTable::seqScanRead(uint8_t *pos, char *buf)
 
876
void MSRepositoryTable::seqScanRead(unsigned char *pos, char *buf)
877
877
{
878
878
        seqScanRead(mi_uint4korr( pos), mi_uint8korr(pos +4), buf);
879
879
}
1054
1054
                                break;
1055
1055
                        case 'M': // MD5_Checksum
1056
1056
                                if (storage_type == MS_STANDARD_STORAGE) {
1057
 
                                        char checksum[sizeof(Md5Digest) *2];
 
1057
                                        char checksum[sizeof(Md5Digest) *2 +1];
1058
1058
                                        
1059
1059
                                        ASSERT(strcmp(curr_field->field_name, "MD5_Checksum") == 0);
1060
 
                                        cs_bin_to_hex(sizeof(Md5Digest) *2, checksum, sizeof(Md5Digest), &(blob->rb_blob_checksum_md5d));
 
1060
                                        cs_bin_to_hex(sizeof(Md5Digest) *2 +1, checksum, sizeof(Md5Digest), &(blob->rb_blob_checksum_md5d));
1061
1061
                                        curr_field->store(checksum, sizeof(Md5Digest) *2, system_charset_info);
1062
1062
                                        setNotNullInRecord(curr_field, buf);
1063
1063
                                        
1343
1343
        return sizeof(iRefDataUsed) + sizeof(iRefDataPos) + sizeof(iRefCurrentIndex) + sizeof(iRefCurrentOffset);
1344
1344
}
1345
1345
 
1346
 
void MSReferenceTable::seqScanPos(uint8_t *pos)
 
1346
void MSReferenceTable::seqScanPos(unsigned char *pos)
1347
1347
{
1348
1348
        mi_int4store(pos, iRefCurrentDataPos); pos +=4;
1349
1349
        mi_int4store(pos, iRefCurrentDataUsed);pos +=4; 
1351
1351
        mi_int8store(pos, iRefCurrentOffset);
1352
1352
}
1353
1353
 
1354
 
void MSReferenceTable::seqScanRead(uint8_t *pos, char *buf)
 
1354
void MSReferenceTable::seqScanRead(unsigned char *pos, char *buf)
1355
1355
{
1356
1356
        iRefDataPos = mi_uint4korr( pos); pos +=4;
1357
1357
        iRefDataUsed = mi_uint4korr(pos); pos +=4;
1808
1808
        return sizeof(iMetCurrentDataPos) + sizeof(iMetCurrentDataSize) + sizeof(iMetCurrentBlobRepo) + sizeof(iMetCurrentBlobOffset);
1809
1809
}
1810
1810
 
1811
 
void MSMetaDataTable::seqScanPos(uint8_t *pos)
 
1811
void MSMetaDataTable::seqScanPos(unsigned char *pos)
1812
1812
{
1813
1813
        mi_int4store(pos, iMetCurrentDataPos); pos +=4;
1814
1814
        mi_int4store(pos, iMetCurrentDataSize);pos +=4; 
1816
1816
        mi_int8store(pos, iMetCurrentBlobOffset);
1817
1817
}
1818
1818
 
1819
 
void MSMetaDataTable::seqScanRead(uint8_t *pos, char *buf)
 
1819
void MSMetaDataTable::seqScanRead(unsigned char *pos, char *buf)
1820
1820
{
1821
1821
        iMetStateSaved = false;
1822
1822
        iMetDataPos = mi_uint4korr( pos); pos +=4;
2389
2389
MSSystemTableShare::~MSSystemTableShare()
2390
2390
{
2391
2391
#ifdef DRIZZLED
2392
 
        myThrLock.unlock();
 
2392
        myThrLock.deinit();
2393
2393
#else
2394
2394
        thr_lock_delete(&myThrLock);
2395
2395
#endif