/*
- * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2022 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the Apache License 2.0 (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
#endif
#include "dso_local.h"
-#include "e_os.h"
+#include "internal/e_os.h"
#ifdef DSO_DLFCN
*/
if (!filespec2 || (filespec1 != NULL && filespec1[0] == '/')) {
merged = OPENSSL_strdup(filespec1);
- if (merged == NULL) {
- ERR_raise(ERR_LIB_DSO, ERR_R_MALLOC_FAILURE);
+ if (merged == NULL)
return NULL;
- }
}
/*
* If the first file specification is missing, the second one rules.
*/
else if (!filespec1) {
merged = OPENSSL_strdup(filespec2);
- if (merged == NULL) {
- ERR_raise(ERR_LIB_DSO, ERR_R_MALLOC_FAILURE);
+ if (merged == NULL)
return NULL;
- }
} else {
/*
* This part isn't as trivial as it looks. It assumes that the
len--;
}
merged = OPENSSL_malloc(len + 2);
- if (merged == NULL) {
- ERR_raise(ERR_LIB_DSO, ERR_R_MALLOC_FAILURE);
+ if (merged == NULL)
return NULL;
- }
strcpy(merged, filespec2);
merged[spec2len] = '/';
strcpy(&merged[spec2len + 1], filespec1);
return len;
}
- /* TODO: what error report does this attach to? */
ERR_add_error_data(2, "dlfcn_pathbyaddr(): ", dlerror());
# endif
return -1;