sizeof(struct Node *) <- isn't this wrong??
for a node you should allocate sizeof(struct node) otherwise you allocate only pointer size space (4 or 8 bytes?)
Yes, this is the problem, you should be calling malloc(sizeof(struct Node)) .
However, you can make life easier using new and delete, like this
// in push()
Node* temp = new Node;
// later, in pop()
delete temp;
And, I just noticed, in pop(), why are you calling malloc() on temp again, then immediately assigning temp to headNode? Don't malloc temp in pop().
You need to understand memory allocation a little more, then you should be able to tackle this problem fine.