Use a separate loop. calloc only gives all bits zero, and there is no guarantee that 0.0 is represented as all bits zero.