Skip to content

Commit

Permalink
btrfs-progs: fix scrub error return from pthread_mutex_lock
Browse files Browse the repository at this point in the history
If pthread_mutex_lock() fails it returns the error in ret,
and does not set errno.

Signed-off-by: Eric Sandeen <[email protected]>
  • Loading branch information
Eric Sandeen authored and kdave committed Mar 10, 2013
1 parent b79d4a2 commit c3d5897
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmds-scrub.c
Original file line number Diff line number Diff line change
Expand Up @@ -763,7 +763,7 @@ static int scrub_write_progress(pthread_mutex_t *m, const char *fsid,

ret = pthread_mutex_lock(m);
if (ret) {
err = -errno;
err = -ret;
goto out;
}

Expand Down

0 comments on commit c3d5897

Please sign in to comment.