Problem 1955

Summary: pdb4dna: malloc(): memory corruption: 0
Product: Examples/Extended Reporter: Duurenbuyan Baatar <cosmosduuree02>
Component: medical/dnaAssignee: Sebastien Incerti <incerti>
Status: RESOLVED INVALID    
Severity: normal    
Priority: P4    
Version: 10.3   
Hardware: PC   
OS: Linux   

Description Duurenbuyan Baatar 2017-03-17 03:35:45 CET
I trying to build another molecule in Geant4 using your application "pdb4dna".
In the case of my .pdb file, total number of atoms in each residue (nbAtom) is 52!
"pdb4dna" successfully reading .pdb file when nbAtom<49. But, it does not read .pdb file when nbAtom more than 49.
Error on display:
*** Error in `./pdb4dna': malloc(): memory corruption: 0
En example of my .pdb file:
ATOM      1  N   POPCA   1     -85.938 -67.912  20.706
ATOM      2  C11 POPCA   1     -85.233 -66.984  21.693
ATOM      3  C12 POPCA   1     -86.672 -67.098  19.681
....................
ATOM     48 C312 POPCA   1     -85.321 -63.221   7.272
ATOM     49 C313 POPCA   1     -84.516 -62.900   6.005
ATOM     50 C314 POPCA   1     -85.163 -63.436   4.724
ATOM     51 C315 POPCA   1     -84.323 -63.139   3.477
ATOM     52 C316 POPCA   1     -84.941 -63.684   2.189

Please advice me, how to solve this problem and/or where is use the "free(a);" in PDBlib.cc?

Best regards,
B.Duurenbuyan.
Comment 1 Gabriele Cosmo 2017-03-17 09:06:24 CET
*** Problem 1954 has been marked as a duplicate of this problem. ***
Comment 2 Sebastien Incerti 2017-03-17 19:49:21 CET
Hello,

- does the pdb4dna example work on your system with the provided 1ZBB.pdb file ?

- are you using the last version of Geant4 ?

Thanks

SI
Comment 3 Duurenbuyan Baatar 2017-03-21 06:01:26 CET
Hello,
-	1ZBB.pdb works fine on my machine.
-	Sure, I am using last version of Geant4
-	I’m trying to build popc128.pdb (lipid with water molecules) in pdb4dna example. Then Geant4 makes error on display. *** Error in ‘./pdb4dna’:malloc(): memory corruption: 0 
-	Pdb file source: http://people.ucalgary.ca/~tieleman/download.html
Thanks 
Duurenbuyan.B
Comment 4 Sebastien Incerti 2017-03-21 07:38:44 CET
The file you indicate is not directly from the PDB databank.

If you want pdb4dna to be tested & adapted for such files, you may contact the person in charge at http://pdb4dna.in2p3.fr 

Thank you.