Malware Self Deletion Using Process Injection

Saw a video titled Self Deleting Malware from a guy called Crow. Very interesting way of achieving file deletion, thought I could do it differently using this method.

With the above code once the pipe has been created it will wait for a message to be sent, only one message can be sent to this pipe as as soon as the pipe handler receives a message it assumes that is the path of the file to be deleted. To alter, create pipe communication handler. Could also achieve this using child processes and anon pipes , however I just prefer this way.