Skip to content
Permalink
Browse files

Fix for Windows (MingW) where dirname modifies the passed buffer

  • Loading branch information...
decke committed Aug 28, 2018
1 parent b145dd7 commit 222eddac8a3fa5098b35653377b91ebcb36082ec
Showing with 4 additions and 1 deletion.
  1. +4 −1 drmdecrypt.c
@@ -477,7 +477,10 @@ int main(int argc, char *argv[])

/* set and verify outdir */
if(strlen(outdir) < 1)
strcpy(outdir, dirname(argv[optind]));
{
strcpy(outdir, argv[optind]);
strcpy(outdir, dirname(outdir));
}

if(outdir[strlen(outdir)-1] != '/')
strcat(outdir, "/");

0 comments on commit 222edda

Please sign in to comment.
You can’t perform that action at this time.