From: Pasi Kallinen Date: Wed, 31 Aug 2011 14:42:37 +0000 (+0000) Subject: Fix the "unlink" command so it actually works. X-Git-Tag: v1.6.1-roc-dev~121 X-Git-Url: https://skyeroc.xyz/gitweb/?a=commitdiff_plain;h=11dfabda893866d7597db90b2cb441c7a2968f2d;p=dgamelaunch Fix the "unlink" command so it actually works. git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@589 db0b04b0-f4d1-0310-9a6d-de3e77497b0e --- diff --git a/dgl-common.c b/dgl-common.c index c91de48..dd6221d 100644 --- a/dgl-common.c +++ b/dgl-common.c @@ -219,7 +219,7 @@ dgl_exec_cmdqueue(struct dg_cmdpart *queue, int game, struct dg_user *me) if (p1 && (access(p1, F_OK) != 0)) mkdir(p1, 0755); break; case DGLCMD_UNLINK: - if (p1 && (access(p1, F_OK) != 0)) unlink(p1); + if (p1 && (access(p1, F_OK) == 0)) unlink(p1); break; case DGLCMD_CHDIR: if (p1) {