The resource destruction handler (either normal or persistent resources) has the following prototype:
참고: One important thing to mention: If your resource is a rather complex structure which also contains pointers to memory you allocated during runtime you have to free them before freeing the resource itself!