Project

General

Profile

Bug #7934

sa_init() should use multi-threaded errno

Added by Yuri Pankov over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
lib - userland libraries
Start date:
2017-03-03
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:

Description

Currently sa_init() doesn't use standard errno approach (#include <errno.h>), instead it uses:
http://src.illumos.org/source/xref/illumos-gate/usr/src/lib/libshare/common/libshare.c#882

This leads to races with code in other threads, as it modifies global errno.


Files

7934.c (908 Bytes) 7934.c Yuri Pankov, 2017-03-03 07:13 PM
#1

Updated by Yuri Pankov over 3 years ago

#2

Updated by Electric Monk over 3 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 50 to 100

git commit 015408caf0806500740413126a0215c7493f4bdf

commit  015408caf0806500740413126a0215c7493f4bdf
Author: Jean McCormack <jean.mccormack@nexenta.com>
Date:   2017-03-05T17:21:17.000Z

    7934 sa_init() should use multi-threaded errno
    Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
    Reviewed by: Steve Peng <steve.peng@nexenta.com>
    Reviewed by: Evan Layton <evan.layton@nexenta.com>
    Reviewed by: Alexander Eremin <alexander.eremin@nexenta.com>
    Reviewed by: Rick McNeal <rick.mcneal@nexenta.com>
    Reviewed by: Toomas Soome <tsoome@me.com>
    Reviewed by: Jason King <jason.brian.king@gmail.com>
    Approved by: Robert Mustacchi <rm@joyent.com>

Also available in: Atom PDF