diff options
author | Sverker Eriksson <[email protected]> | 2018-03-28 09:43:53 +0200 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2018-03-28 09:43:53 +0200 |
commit | f274b4cb369e1d4d8474c80595a992959770abf9 (patch) | |
tree | 44c44d9101ee58a156bca56d2cde4e3963bf4ca8 /erts/emulator/beam/erl_bif_ddll.c | |
parent | ce212ce8241e57c344c55df53b20965181cc6756 (diff) | |
parent | 39cf4e75f31e9abe46c9fe39000368c1243fdcf3 (diff) | |
download | otp-f274b4cb369e1d4d8474c80595a992959770abf9.tar.gz otp-f274b4cb369e1d4d8474c80595a992959770abf9.tar.bz2 otp-f274b4cb369e1d4d8474c80595a992959770abf9.zip |
Merge branch 'sverker/driver-taints/OTP-14960'
* sverker/driver-taints/OTP-14960:
erts: Include foreign static linked drivers in taints
erts: Fix harmless bug in macro IS_DRIVER_VERSION_GE
erts: Remove our own NIF modules from "taints"
erts: Refactor erts_static_nif_get_nif_init
erts: Add dynamic loaded drivers to list of "taints"
Diffstat (limited to 'erts/emulator/beam/erl_bif_ddll.c')
-rw-r--r-- | erts/emulator/beam/erl_bif_ddll.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/erts/emulator/beam/erl_bif_ddll.c b/erts/emulator/beam/erl_bif_ddll.c index 579e9b12f4..294bce115f 100644 --- a/erts/emulator/beam/erl_bif_ddll.c +++ b/erts/emulator/beam/erl_bif_ddll.c @@ -1505,6 +1505,7 @@ static int do_load_driver_entry(DE_Handle *dh, char *path, char *name) res = ERL_DE_LOAD_ERROR_BAD_NAME; goto error; } + erts_atomic_init_nob(&(dh->refc), (erts_aint_t) 0); erts_atomic32_init_nob(&dh->port_count, 0); dh->full_path = erts_alloc(ERTS_ALC_T_DDLL_HANDLE, sys_strlen(path) + 1); @@ -1512,7 +1513,7 @@ static int do_load_driver_entry(DE_Handle *dh, char *path, char *name) dh->flags = 0; dh->status = ERL_DE_OK; - if (erts_add_driver_entry(dp, dh, 1) != 0 /* io.c */) { + if (erts_add_driver_entry(dp, dh, 1, 1) != 0 /* io.c */) { /* * The init in the driver struct did not return 0 */ |