Thank you for the explanation, understood that pointer will stay alive after macro exits. What if I write a c++ program and compile with root? Will it be any difference between pointer and object? Like:
Then that’s a C++ question. Normal objects vanish automatically when they are out of scope (basically when exiting { } ) and pointers must be deleted otherwise you get a memory leak.