Use precondition instead of raising an exception.
Fixed bug#14062: CURL dynamic library not found exception is causing an internal failure in WEL git-svn-id: https://svn.origo.ethz.ch/eiffelstudio/trunk/Src/library/cURL@72612 8089f293-4706-0410-a29e-feb5c42a2edf
This commit is contained in:
@@ -16,16 +16,14 @@ feature -- Command
|
||||
|
||||
global_init is
|
||||
-- Declared as curl_global_init().
|
||||
require
|
||||
dynamic_library_exists: is_dynamic_library_exists
|
||||
local
|
||||
l_ptr: POINTER
|
||||
l_exception: CURL_DYNAMIC_LIBRARY_NOT_FOUND_EXCEPTION
|
||||
do
|
||||
l_ptr := api_loader.safe_load_api (module_name, "curl_global_init")
|
||||
if l_ptr /= default_pointer then
|
||||
c_curl_global_init (l_ptr, {CURL_GLOBAL_CONSTANTS}.curl_global_all);
|
||||
else
|
||||
create l_exception.make
|
||||
l_exception.raise
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user