debug: Remove two pointless assignments
authorVolker Lendecke <vl@samba.org>
Tue, 29 Jul 2014 15:47:07 +0000 (15:47 +0000)
committerMichael Adam <obnox@samba.org>
Thu, 31 Jul 2014 16:49:47 +0000 (18:49 +0200)
"goto done:" jumps to that exact assignment :-)

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
lib/util/debug.c

index 9fdad54edb905d9397c21d9fcdd5b0b7378d77b9..d96fcc5322f13a1df108ee015a0e090614097d35 100644 (file)
@@ -789,7 +789,6 @@ static int Debug1( const char *format_str, ... )
                if (state.fd > 0)
                        (void)vdprintf( state.fd, format_str, ap );
                va_end( ap );
-               errno = old_errno;
                goto done;
        }
 
@@ -802,7 +801,6 @@ static int Debug1( const char *format_str, ... )
                        int fd = open( state.debugf, O_WRONLY|O_APPEND|O_CREAT, 0644 );
                        (void)umask( oldumask );
                        if(fd == -1) {
-                               errno = old_errno;
                                goto done;
                        }
                        state.fd = fd;