summaryrefslogtreecommitdiff
path: root/backend/magicolor.c
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2017-05-24 21:03:56 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2017-05-24 21:03:56 +0200
commit58912f68c2489bcee787599837447e0d64dfd61a (patch)
treedda50aadde35fe152da1a8d50769987ace0f1496 /backend/magicolor.c
parentcfd27ef2ad8b005fd47ab41ef29b71d9e3d48201 (diff)
New upstream version 1.0.27upstream/1.0.27
Diffstat (limited to 'backend/magicolor.c')
-rw-r--r--backend/magicolor.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/backend/magicolor.c b/backend/magicolor.c
index 660f517..d3af142 100644
--- a/backend/magicolor.c
+++ b/backend/magicolor.c
@@ -1385,7 +1385,6 @@ static SANE_Status
mc_init_parameters(Magicolor_Scanner * s)
{
int dpi, optres;
- struct mode_param *mparam;
DBG(5, "%s\n", __func__);
@@ -1394,8 +1393,6 @@ mc_init_parameters(Magicolor_Scanner * s)
dpi = s->val[OPT_RESOLUTION].w;
optres = s->hw->cap->optical_res;
- mparam = &mode_params[s->val[OPT_MODE].w];
-
if (SANE_UNFIX(s->val[OPT_BR_Y].w) == 0 ||
SANE_UNFIX(s->val[OPT_BR_X].w) == 0)
return SANE_STATUS_INVAL;
@@ -1521,6 +1518,7 @@ mc_read(struct Magicolor_Scanner *s)
****************************************************************************/
+#if HAVE_LIBSNMP
static struct MagicolorCap *
mc_get_device_from_identification (const char*ident)
{
@@ -1531,6 +1529,7 @@ mc_get_device_from_identification (const char*ident)
}
return NULL;
}
+#endif
/*
@@ -1970,10 +1969,10 @@ mc_network_discovery(const char*host)
init_snmp("sane-magicolor-backend");
snmp_sess_init (&session);
session.version = SNMP_VERSION_2c;
- session.community = "public";
- session.community_len = strlen (session.community);
+ session.community = (u_char *) "public";
+ session.community_len = strlen ((char *)session.community);
if (host) {
- session.peername = host;
+ session.peername = (char *) host;
} else {
/* Do a network discovery via a broadcast */
session.peername = "255.255.255.255";