-
Type:
Improvement
-
Status: Resolved
-
Priority:
Trivial
-
Resolution: Fixed
-
Affects Version/s: 7.0.0
-
Fix Version/s: 7.0.0
-
Labels:None
-
Environment:OBT
-
Pull Request URL:
2 new defect(s) introduced to HPCC-Platform found with Coverity Scan.
*** CID 1464301: Null pointer dereferences (FORWARD_NULL) /mnt/disk1/home/vamosax/build/CE/platform/HPCC-Platform/roxie/ccd/ccdfile.cpp: 2137 in CResolvedFile::getTranslators(int, IOutputMetaData *, IOutputMetaData *, RecordTranslationMode, bool) const() 2131 if (!translator || !translator->canTranslate()) 2132 throw MakeStringException(ROXIE_MISMATCH, "Untranslatable record layout mismatch detected for file %s", subname); 2133 if (translator->needsTranslate()) 2134 \{ 2135 if (mode == RecordTranslationMode::None) 2136 throw MakeStringException(ROXIE_MISMATCH, "Translatable record layout mismatch detected for file %s, but translation disabled", subname); >>> CID 1464301: Null pointer dereferences (FORWARD_NULL) >>> Passing null pointer "actual" to "queryRecordAccessor", which >>> dereferences it. (The dereference happens because this is a virtual >>> function call.) 2137 keyedTranslator.setown(createKeyTranslator(actual->queryRecordAccessor(true), expected->queryRecordAccessor(true))); // NOTE - index cases should check (elsewhere) that this is empty. 2138 if (isIndex && keyedTranslator->needsTranslate()) 2139 throw MakeStringException(ROXIE_MISMATCH, "Record layout mismatch detected in keyed fields for file %s", subname); 2140 2141 } 2142 } ________________________________________________________________________________________________________ *** CID 1464302: Uninitialized members (UNINIT_CTOR) /mnt/disk1/home/vamosax/build/CE/platform/HPCC-Platform/plugins/py3embed/py3embed.cpp: 271 in py3embed::Python3xGlobalState::Python3xGlobalState()() 265 // If Py_Initialize is called when stdin is set to a directory, it calls exit() 266 // We don't want that to happen - just disable Python support in such situations 267 struct stat sb; 268 if (fstat(fileno(stdin), &sb) == 0 && S_ISDIR(sb.st_mode)) 269 \{ 270 initialized = false; >>> CID 1464302: Uninitialized members (UNINIT_CTOR) >>> Non-static class member "tstate" is not initialized in this constructor nor in any functions that it calls. 271 return; 272 } 273 #endif 274 #ifndef _WIN32 275 // We need to ensure all symbols in the python3.x so are loaded - due to bugs in some distro's python installations 276 // However this will likely break python2.