Bug #7968 Compile error + warnings in 'NdbDictionaryImpl.hpp' + 'NdbDictionaryImpl.cpp'

Submitted: 17 Jan 2005 19:23 Modified: 18 Jan 2005 12:48
Reporter: Joerg Bruehe Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Compiling Severity:S3 (Non-critical)
Version:5.0.3-pre OS:Other (IRIX)
Assigned to: Tomas Ulin CPU Architecture:Any

[17 Jan 2005 19:23] Joerg Bruehe
Description:
In the current build of 5.0.3, based on changeSet
  1.1771 05/01/13 15:10:12 lenz@mysql.com +1 -0
  - keep 5.0.3-alpha version string (after-merge fix)

we get various warnings and an error for these two files:

1) This is a fatal error:
cc-1101 CC: ERROR File = NdbDictionaryImpl.cpp, Line = 1361
  "i" has already been declared in the current scope.
      for(int i = 31; i>=0; i--){
              ^

2) Warning about functions being redeclared 'inline' after being called - on other platforms, this has led to fatal errors:
cc-1460 CC: WARNING File = NdbDictionaryImpl.hpp, Line = 642
  Function function "NdbDictionaryImpl::get_local_table_info" is redeclared
          "inline" after being called.
  NdbDictionaryImpl::get_local_table_info(const char * internalTableName,
                     ^

3) Warnings about unused variables (reported here for completeness only):
cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 1708
  The variable "tableVersion" was declared but never referenced.
    Uint32 tableVersion= conf->tableVersion;
           ^

cc-1552 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 1801
  The variable "res" is set but never used.
    int res;
        ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2697
  The variable "subscriptionId" was declared but never referenced.
    Uint32 subscriptionId = subStopConf->subscriptionId;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2698
  The variable "subscriptionKey" was declared but never referenced.
    Uint32 subscriptionKey = subStopConf->subscriptionKey;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2699
  The variable "subscriberData" was declared but never referenced.
    Uint32 subscriberData = subStopConf->subscriberData;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2715
  The variable "subscriptionId" was declared but never referenced.
    Uint32 subscriptionId = subStopRef->subscriptionId;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2716
  The variable "subscriptionKey" was declared but never referenced.
    Uint32 subscriptionKey = subStopRef->subscriptionKey;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2717
  The variable "subscriberData" was declared but never referenced.
    Uint32 subscriberData = subStopRef->subscriberData;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2734
  The variable "subscriptionId" was declared but never referenced.
    Uint32 subscriptionId = subStartConf->subscriptionId;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2735
  The variable "subscriptionKey" was declared but never referenced.
    Uint32 subscriptionKey = subStartConf->subscriptionKey;
           ^

cc-1174 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2738
  The variable "subscriberData" was declared but never referenced.
    Uint32 subscriberData = subStartConf->subscriberData;
           ^

cc-1552 CC: WARNING File = NdbDictionaryImpl.cpp, Line = 2801
  The variable "r" is set but never used.
    int r;
        ^

How to repeat:
Compile with NDB on octane2.

Suggested fix:
Code all inline functions bottom-up.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.038 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.