Skip to content

Instantly share code, notes, and snippets.

@JubbaSmail
Created November 13, 2014 10:08
Show Gist options
  • Select an option

  • Save JubbaSmail/38528b8f0f77759096fd to your computer and use it in GitHub Desktop.

Select an option

Save JubbaSmail/38528b8f0f77759096fd to your computer and use it in GitHub Desktop.
#include <windows.h>
#include <stdio.h>
#if define UNICODE
#define DeleteFile DeleteFileW
#else
#define DeleteFile DeleteFileA
#endif
int main(int argc, LPTSTR argv[])
{
if (argc != 2) {
fprintf(stderr, "Usage: myDel filename\n");
return 1;
}
DeleteFile(argv[1]);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment