@pmoubed If it's just one routine, as in your question, it's not a leak any more than anything else allocated in main. If you're creating lots of them, then it's probably a leak. Like Volker said, "it depends"; your example is too vague to say what is the correct way to handle it so I gave options.
↧