kopia lustrzana https://gitlab.com/sane-project/backends
Added sane_reload_devices() to sane_init().
Adding sane_reload_devices() to sane_init() required sane_init() to be moved below the sane_reload_devices() declaration. This restores the original functionality present before I split the sane_reload_devices() code out of sane_init() so that it could be called from sane_get_devices().merge-requests/1/head
rodzic
11b3604e92
commit
33bb529c5f
|
@ -7527,29 +7527,6 @@ attach_one_usb (const char* dev)
|
|||
attach (dev, AV_USB, 0);
|
||||
return SANE_STATUS_GOOD;
|
||||
}
|
||||
|
||||
SANE_Status
|
||||
sane_init (SANE_Int* version_code, SANE_Auth_Callback authorize)
|
||||
{
|
||||
authorize = authorize; /* silence gcc */
|
||||
|
||||
DBG_INIT();
|
||||
|
||||
#ifdef AVISION_STATIC_DEBUG_LEVEL
|
||||
DBG_LEVEL = AVISION_STATIC_DEBUG_LEVEL;
|
||||
#endif
|
||||
|
||||
DBG (3, "sane_init:(Version: %i.%i Build: %i)\n",
|
||||
SANE_CURRENT_MAJOR, V_MINOR, BACKEND_BUILD);
|
||||
|
||||
/* must come first */
|
||||
sanei_thread_init ();
|
||||
|
||||
if (version_code)
|
||||
*version_code = SANE_VERSION_CODE (SANE_CURRENT_MAJOR, V_MINOR, BACKEND_BUILD);
|
||||
|
||||
return SANE_STATUS_GOOD;
|
||||
}
|
||||
|
||||
static SANE_Status
|
||||
sane_reload_devices (void)
|
||||
|
@ -7723,6 +7700,31 @@ sane_reload_devices (void)
|
|||
return SANE_STATUS_GOOD;
|
||||
}
|
||||
|
||||
SANE_Status
|
||||
sane_init (SANE_Int* version_code, SANE_Auth_Callback authorize)
|
||||
{
|
||||
authorize = authorize; /* silence gcc */
|
||||
|
||||
DBG_INIT();
|
||||
|
||||
#ifdef AVISION_STATIC_DEBUG_LEVEL
|
||||
DBG_LEVEL = AVISION_STATIC_DEBUG_LEVEL;
|
||||
#endif
|
||||
|
||||
DBG (3, "sane_init:(Version: %i.%i Build: %i)\n",
|
||||
SANE_CURRENT_MAJOR, V_MINOR, BACKEND_BUILD);
|
||||
|
||||
/* must come first */
|
||||
sanei_thread_init ();
|
||||
|
||||
if (version_code)
|
||||
*version_code = SANE_VERSION_CODE (SANE_CURRENT_MAJOR, V_MINOR, BACKEND_BUILD);
|
||||
|
||||
sane_reload_devices ();
|
||||
|
||||
return SANE_STATUS_GOOD;
|
||||
}
|
||||
|
||||
void
|
||||
sane_exit (void)
|
||||
{
|
||||
|
|
Ładowanie…
Reference in New Issue