Lines Matching refs:dso
47 int DSO_free(DSO *dso) in DSO_free() argument
51 if (dso == NULL) in DSO_free()
54 if (CRYPTO_DOWN_REF(&dso->references, &i) <= 0) in DSO_free()
57 REF_PRINT_COUNT("DSO", dso); in DSO_free()
62 if ((dso->flags & DSO_FLAG_NO_UNLOAD_ON_FREE) == 0) { in DSO_free()
63 if ((dso->meth->dso_unload != NULL) && !dso->meth->dso_unload(dso)) { in DSO_free()
69 if ((dso->meth->finish != NULL) && !dso->meth->finish(dso)) { in DSO_free()
74 sk_void_free(dso->meth_data); in DSO_free()
75 OPENSSL_free(dso->filename); in DSO_free()
76 OPENSSL_free(dso->loaded_filename); in DSO_free()
77 CRYPTO_FREE_REF(&dso->references); in DSO_free()
78 OPENSSL_free(dso); in DSO_free()
82 int DSO_flags(DSO *dso) in DSO_flags() argument
84 return ((dso == NULL) ? 0 : dso->flags); in DSO_flags()
87 int DSO_up_ref(DSO *dso) in DSO_up_ref() argument
91 if (dso == NULL) { in DSO_up_ref()
96 if (CRYPTO_UP_REF(&dso->references, &i) <= 0) in DSO_up_ref()
99 REF_PRINT_COUNT("DSO", dso); in DSO_up_ref()
104 DSO *DSO_load(DSO *dso, const char *filename, DSO_METHOD *meth, int flags) in DSO_load() argument
109 if (dso == NULL) { in DSO_load()
122 ret = dso; in DSO_load()
158 DSO_FUNC_TYPE DSO_bind_func(DSO *dso, const char *symname) in DSO_bind_func() argument
162 if ((dso == NULL) || (symname == NULL)) { in DSO_bind_func()
166 if (dso->meth->dso_bind_func == NULL) { in DSO_bind_func()
170 if ((ret = dso->meth->dso_bind_func(dso, symname)) == NULL) { in DSO_bind_func()
187 long DSO_ctrl(DSO *dso, int cmd, long larg, void *parg) in DSO_ctrl() argument
189 if (dso == NULL) { in DSO_ctrl()
199 return dso->flags; in DSO_ctrl()
201 dso->flags = (int)larg; in DSO_ctrl()
204 dso->flags |= (int)larg; in DSO_ctrl()
209 if ((dso->meth == NULL) || (dso->meth->dso_ctrl == NULL)) { in DSO_ctrl()
213 return dso->meth->dso_ctrl(dso, cmd, larg, parg); in DSO_ctrl()
216 const char *DSO_get_filename(DSO *dso) in DSO_get_filename() argument
218 if (dso == NULL) { in DSO_get_filename()
222 return dso->filename; in DSO_get_filename()
225 int DSO_set_filename(DSO *dso, const char *filename) in DSO_set_filename() argument
229 if ((dso == NULL) || (filename == NULL)) { in DSO_set_filename()
233 if (dso->loaded_filename) { in DSO_set_filename()
241 OPENSSL_free(dso->filename); in DSO_set_filename()
242 dso->filename = copied; in DSO_set_filename()
246 char *DSO_merge(DSO *dso, const char *filespec1, const char *filespec2) in DSO_merge() argument
250 if (dso == NULL || filespec1 == NULL) { in DSO_merge()
254 if ((dso->flags & DSO_FLAG_NO_NAME_TRANSLATION) == 0) { in DSO_merge()
255 if (dso->merger != NULL) in DSO_merge()
256 result = dso->merger(dso, filespec1, filespec2); in DSO_merge()
257 else if (dso->meth->dso_merger != NULL) in DSO_merge()
258 result = dso->meth->dso_merger(dso, filespec1, filespec2); in DSO_merge()
263 char *DSO_convert_filename(DSO *dso, const char *filename) in DSO_convert_filename() argument
267 if (dso == NULL) { in DSO_convert_filename()
272 filename = dso->filename; in DSO_convert_filename()
277 if ((dso->flags & DSO_FLAG_NO_NAME_TRANSLATION) == 0) { in DSO_convert_filename()
278 if (dso->name_converter != NULL) in DSO_convert_filename()
279 result = dso->name_converter(dso, filename); in DSO_convert_filename()
280 else if (dso->meth->dso_name_converter != NULL) in DSO_convert_filename()
281 result = dso->meth->dso_name_converter(dso, filename); in DSO_convert_filename()