]> git.ipfire.org Git - thirdparty/mlmmj.git/commitdiff
Remove call to myunlock, since it's closed right after
authormmj <none@none>
Thu, 13 Jan 2005 19:37:11 +0000 (06:37 +1100)
committermmj <none@none>
Thu, 13 Jan 2005 19:37:11 +0000 (06:37 +1100)
src/mlmmj-sub.c
src/mlmmj-unsub.c

index 73372b8298506c27110678649c11b12af1fa8a5b..ec06a0e6b38b5b9c5a1f5b187189578cf66e78e5 100644 (file)
@@ -391,9 +391,8 @@ int main(int argc, char **argv)
                        address[len] = 0;
                }
        } else {
-               myunlock(subfilefd);
-               myfree(subfilename);
                close(subfilefd);
+               myfree(subfilename);
                
                return EXIT_SUCCESS;
        }
index a9f8e98aa1b3583f8861318a3ec34137310842b7..780c0ce637e81509a54d82b8552bb9722591fde8 100644 (file)
@@ -455,7 +455,6 @@ int main(int argc, char **argv)
                if(subwrite == -1){
                        log_error(LOG_ARGS, "Could not open '%s'",
                                        subwritename);
-                       myunlock(subread);
                        close(subread);
                        myfree(subreadname);
                        myfree(subwritename);
@@ -466,7 +465,6 @@ int main(int argc, char **argv)
                if(wlock < 0) {
                        log_error(LOG_ARGS, "Error locking '%s'",
                                        subwritename);
-                       myunlock(subread);
                        close(subread);
                        close(subwrite);
                        myfree(subreadname);
@@ -476,8 +474,6 @@ int main(int argc, char **argv)
 
                unsubres = unsubscribe(subread, subwrite, address);
                if(unsubres < 0) {
-                       myunlock(subread);
-                       myunlock(subwrite);
                        close(subread);
                        close(subwrite);
                        unlink(subwritename);
@@ -493,8 +489,6 @@ int main(int argc, char **argv)
                                log_error(LOG_ARGS,
                                        "Could not rename '%s' to '%s'",
                                        subwritename, subreadname);
-                               myunlock(subread);
-                               myunlock(subwrite);
                                close(subread);
                                close(subwrite);
                                myfree(subreadname);
@@ -504,8 +498,6 @@ int main(int argc, char **argv)
                } else /* unsubres == 0, no subscribers left */
                        unlink(subwritename);
 
-               myunlock(subread);
-               myunlock(subwrite);
                close(subread);
                close(subwrite);
                myfree(subreadname);