This happens every second time I try to free the list. The first time the list is populated nicely. What I am doing is just adding the items to the list and repopulating the list by first clearing it and then loading items from a QListWidgetItem array.

And when I don't clear the list the program just runs fine.

Is there any other method through which I could achieve the emptying of the list widget ?