Bug #36610 DblqMain.cpp sp not initialized
Submitted: 9 May 2008 3:40 Modified: 13 Feb 2009 3:55
Reporter: jack andrews Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Cluster: Cluster (NDB) storage engine Severity:S3 (Non-critical)
Version:5.0.48 OS:Any
Assigned to: jack andrews CPU Architecture:Any

[9 May 2008 3:40] jack andrews
Description:
>>> DblqMain.cpp
>>> ------------
>>>
>>> ScanRecordPtr sp;
>>> sp.i = recordNo;
>>> c_scanRecordPool.getPtr(scanptr);
>>> if (sp.p->scanState != ScanRecord:confused smileyCAN_FREE){
>>>
>>> sp.p is not initialized
`

How to repeat:
read source

Suggested fix:

change 
  c_scanRecordPool.getPtr(scanptr);
to 
  c_scanRecordPool.getPtr(sp);
[9 May 2008 16:24] Susanne Ebrecht
Many thanks for writing a bug report.

I can't find this in our actual source code anymore but I found similar curiosity and another row:

18810: ScanRecordPtr sp;
18811:    sp.i = recordNo;
18812:    c_scanRecordPool.getPtr(scanptr);
18813:    if (sp.p->scanState != ScanRecord::SCAN_FREE){

File: ./ndb/src/kernel/blocks/dblqh/DblqhMain.cpp

Bitkeeper source code from MySQL 5.0 from 2008-05-08 23:30 (CEST)
[13 Feb 2009 3:55] jack andrews
fix already committed to telco-6.4