Replaced __unused__ with __sane_unused__ to avoid a namespace conflict.

merge-requests/1/head
Frank Zago 2005-09-19 19:57:48 +00:00
rodzic 2428065ee4
commit ab5d790e26
10 zmienionych plików z 51 dodań i 45 usunięć

Wyświetl plik

@ -653,7 +653,7 @@ change_res (int fd, unsigned char res)
} }
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
char f[] = "sane_init"; char f[] = "sane_init";
@ -826,7 +826,7 @@ static const SANE_Device dev[] = {
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, sane_get_devices (const SANE_Device *** device_list,
SANE_Bool __unused__ local_only) SANE_Bool __sane_unused__ local_only)
{ {
static const SANE_Device *devlist[] = { static const SANE_Device *devlist[] = {
dev + 0, 0 dev + 0, 0
@ -1127,7 +1127,7 @@ my_source_mgr;
typedef my_source_mgr *my_src_ptr; typedef my_source_mgr *my_src_ptr;
METHODDEF (void) METHODDEF (void)
sanei_jpeg_init_source (j_decompress_ptr __unused__ cinfo) sanei_jpeg_init_source (j_decompress_ptr __sane_unused__ cinfo)
{ {
/* nothing to do */ /* nothing to do */
} }
@ -1169,7 +1169,7 @@ sanei_jpeg_skip_input_data (j_decompress_ptr cinfo, long num_bytes)
} }
METHODDEF (void) METHODDEF (void)
sanei_jpeg_term_source (j_decompress_ptr __unused__ cinfo) sanei_jpeg_term_source (j_decompress_ptr __sane_unused__ cinfo)
{ {
/* no work necessary here */ /* no work necessary here */
} }
@ -1274,7 +1274,7 @@ sane_start (SANE_Handle handle)
} }
SANE_Status SANE_Status
sane_read (SANE_Handle __unused__ handle, SANE_Byte * data, sane_read (SANE_Handle __sane_unused__ handle, SANE_Byte * data,
SANE_Int max_length, SANE_Int * length) SANE_Int max_length, SANE_Int * length)
{ {
@ -1377,7 +1377,7 @@ sane_read (SANE_Handle __unused__ handle, SANE_Byte * data,
} }
void void
sane_cancel (SANE_Handle __unused__ handle) sane_cancel (SANE_Handle __sane_unused__ handle)
{ {
DBG (127, "sane_cancel() called\n"); DBG (127, "sane_cancel() called\n");
if (Camera.scanning) if (Camera.scanning)
@ -1387,14 +1387,14 @@ sane_cancel (SANE_Handle __unused__ handle)
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, sane_set_io_mode (SANE_Handle __sane_unused__ handle,
SANE_Bool __unused__ non_blocking) SANE_Bool __sane_unused__ non_blocking)
{ {
return SANE_STATUS_UNSUPPORTED; return SANE_STATUS_UNSUPPORTED;
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ * fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ * fd)
{ {
return SANE_STATUS_UNSUPPORTED; return SANE_STATUS_UNSUPPORTED;
} }

Wyświetl plik

@ -433,7 +433,7 @@ leo_identify_scanner (Leo_Scanner * dev)
/* SCSI sense handler. Callback for SANE. */ /* SCSI sense handler. Callback for SANE. */
static SANE_Status static SANE_Status
leo_sense_handler (int scsi_fd, unsigned char *result, void __unused__ *arg) leo_sense_handler (int scsi_fd, unsigned char *result, void __sane_unused__ *arg)
{ {
int asc, ascq, sensekey; int asc, ascq, sensekey;
int len; int len;
@ -1290,7 +1290,7 @@ leo_send_halftone_pattern (Leo_Scanner * dev)
/* Sane entry points */ /* Sane entry points */
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
FILE *fp; FILE *fp;
char dev_name[PATH_MAX]; char dev_name[PATH_MAX];
@ -1337,7 +1337,7 @@ sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize)
} }
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, SANE_Bool __unused__ local_only) sane_get_devices (const SANE_Device *** device_list, SANE_Bool __sane_unused__ local_only)
{ {
Leo_Scanner *dev; Leo_Scanner *dev;
int i; int i;
@ -1911,7 +1911,7 @@ sane_read (SANE_Handle handle, SANE_Byte * buf, SANE_Int max_len,
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocking) sane_set_io_mode (SANE_Handle __sane_unused__ handle, SANE_Bool __sane_unused__ non_blocking)
{ {
SANE_Status status; SANE_Status status;
Leo_Scanner *dev = handle; Leo_Scanner *dev = handle;
@ -1938,7 +1938,7 @@ sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocki
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ * fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ * fd)
{ {
DBG (DBG_proc, "sane_get_select_fd: enter\n"); DBG (DBG_proc, "sane_get_select_fd: enter\n");

Wyświetl plik

@ -840,7 +840,7 @@ get_int_list_index (const SANE_Word list[], const SANE_Word value)
/* SCSI sense handler. Callback for SANE. */ /* SCSI sense handler. Callback for SANE. */
static SANE_Status static SANE_Status
matsushita_sense_handler (int scsi_fd, unsigned char *result, void __unused__ *arg) matsushita_sense_handler (int scsi_fd, unsigned char *result, void __sane_unused__ *arg)
{ {
int asc, ascq, sensekey; int asc, ascq, sensekey;
int len; int len;
@ -1703,7 +1703,7 @@ do_cancel (Matsushita_Scanner * dev)
/* Entry points */ /* Entry points */
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
FILE *fp; FILE *fp;
char dev_name[PATH_MAX]; char dev_name[PATH_MAX];
@ -1750,7 +1750,7 @@ sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize)
} }
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, SANE_Bool __unused__ local_only) sane_get_devices (const SANE_Device *** device_list, SANE_Bool __sane_unused__ local_only)
{ {
Matsushita_Scanner *dev; Matsushita_Scanner *dev;
int i; int i;
@ -2412,7 +2412,7 @@ sane_read (SANE_Handle handle, SANE_Byte * buf, SANE_Int max_len,
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocking) sane_set_io_mode (SANE_Handle __sane_unused__ handle, SANE_Bool __sane_unused__ non_blocking)
{ {
SANE_Status status; SANE_Status status;
Matsushita_Scanner *dev = handle; Matsushita_Scanner *dev = handle;
@ -2436,7 +2436,7 @@ sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocki
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ * fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ * fd)
{ {
DBG (DBG_proc, "sane_get_select_fd: enter\n"); DBG (DBG_proc, "sane_get_select_fd: enter\n");

Wyświetl plik

@ -521,7 +521,7 @@ sceptre_adjust_raster (Sceptre_Scanner * dev, size_t size_in)
* Since this scanner does not have REQUEST SENSE, it is always an * Since this scanner does not have REQUEST SENSE, it is always an
* error if this function is called.*/ * error if this function is called.*/
static SANE_Status static SANE_Status
sceptre_sense_handler (int scsi_fd, unsigned char __unused__ *result, void __unused__ *arg) sceptre_sense_handler (int scsi_fd, unsigned char __sane_unused__ *result, void __sane_unused__ *arg)
{ {
DBG (DBG_proc, "sceptre_sense_handler (scsi_fd = %d)\n", scsi_fd); DBG (DBG_proc, "sceptre_sense_handler (scsi_fd = %d)\n", scsi_fd);
@ -1307,7 +1307,7 @@ sceptre_send_gamma (Sceptre_Scanner * dev)
/* Entry points */ /* Entry points */
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
FILE *fp; FILE *fp;
char dev_name[PATH_MAX]; char dev_name[PATH_MAX];
@ -1354,7 +1354,7 @@ sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize)
} }
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, SANE_Bool __unused__ local_only) sane_get_devices (const SANE_Device *** device_list, SANE_Bool __sane_unused__ local_only)
{ {
Sceptre_Scanner *dev; Sceptre_Scanner *dev;
int i; int i;
@ -1991,7 +1991,7 @@ sane_read (SANE_Handle handle, SANE_Byte * buf, SANE_Int max_len,
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocking) sane_set_io_mode (SANE_Handle __sane_unused__ handle, SANE_Bool __sane_unused__ non_blocking)
{ {
SANE_Status status; SANE_Status status;
Sceptre_Scanner *dev = handle; Sceptre_Scanner *dev = handle;
@ -2018,7 +2018,7 @@ sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocki
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ * fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ * fd)
{ {
DBG (DBG_proc, "sane_get_select_fd: enter\n"); DBG (DBG_proc, "sane_get_select_fd: enter\n");

Wyświetl plik

@ -49,6 +49,9 @@ static const char RCSid_sh[] = "$Header$";
/* ------------------------------------------------------------------------- */ /* ------------------------------------------------------------------------- */
/* /*
* $Log$ * $Log$
* Revision 1.6 2005/09/19 19:57:48 fzago-guest
* Replaced __unused__ with __sane_unused__ to avoid a namespace conflict.
*
* Revision 1.5 2004/11/13 19:53:04 fzago-guest * Revision 1.5 2004/11/13 19:53:04 fzago-guest
* Fixes some warnings. * Fixes some warnings.
* *
@ -540,7 +543,7 @@ static scsiblk window_descriptor_blockB =
/* ==================================================================== */ /* ==================================================================== */
static scsiblk __unused__ *lint_catcher[] = static scsiblk __sane_unused__ *lint_catcher[] =
{&reserve_unitB, {&reserve_unitB,
&release_unitB, &release_unitB,
&inquiryB, &inquiryB,

Wyświetl plik

@ -49,6 +49,9 @@ static const char RCSid_h[] = "$Header$";
/* ------------------------------------------------------------------------- */ /* ------------------------------------------------------------------------- */
/* /*
* $Log$ * $Log$
* Revision 1.7 2005/09/19 19:57:48 fzago-guest
* Replaced __unused__ with __sane_unused__ to avoid a namespace conflict.
*
* Revision 1.6 2004/11/13 19:53:04 fzago-guest * Revision 1.6 2004/11/13 19:53:04 fzago-guest
* Fixes some warnings. * Fixes some warnings.
* *
@ -273,7 +276,7 @@ static int
static int static int
wait_scanner (struct sp15c *s); wait_scanner (struct sp15c *s);
static int __unused__ static int __sane_unused__
sp15c_object_position (struct sp15c *s); sp15c_object_position (struct sp15c *s);
static SANE_Status static SANE_Status
@ -282,7 +285,7 @@ static SANE_Status
static void static void
swap_res (struct sp15c *s); swap_res (struct sp15c *s);
static int __unused__ static int __sane_unused__
sp15c_object_discharge (struct sp15c *s); sp15c_object_discharge (struct sp15c *s);
static int static int

Wyświetl plik

@ -576,7 +576,7 @@ teco_get_inquiry_82 (Teco_Scanner * dev)
/* SCSI sense handler. Callback for SANE. /* SCSI sense handler. Callback for SANE.
* These scanners never set asc or ascq. */ * These scanners never set asc or ascq. */
static SANE_Status static SANE_Status
teco_sense_handler (int __unused__ scsi_fd, unsigned char *result, void __unused__ *arg) teco_sense_handler (int __sane_unused__ scsi_fd, unsigned char *result, void __sane_unused__ *arg)
{ {
int sensekey; int sensekey;
int len; int len;
@ -1468,7 +1468,7 @@ do_cancel (Teco_Scanner * dev)
/* Sane entry points */ /* Sane entry points */
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
FILE *fp; FILE *fp;
char dev_name[PATH_MAX]; char dev_name[PATH_MAX];
@ -1515,7 +1515,7 @@ sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize)
} }
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, SANE_Bool __unused__ local_only) sane_get_devices (const SANE_Device *** device_list, SANE_Bool __sane_unused__ local_only)
{ {
Teco_Scanner *dev; Teco_Scanner *dev;
int i; int i;
@ -2160,7 +2160,7 @@ sane_read (SANE_Handle handle, SANE_Byte * buf, SANE_Int max_len,
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocking) sane_set_io_mode (SANE_Handle __sane_unused__ handle, SANE_Bool __sane_unused__ non_blocking)
{ {
SANE_Status status; SANE_Status status;
Teco_Scanner *dev = handle; Teco_Scanner *dev = handle;
@ -2187,7 +2187,7 @@ sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocki
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ *fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ *fd)
{ {
DBG (DBG_proc, "sane_get_select_fd: enter\n"); DBG (DBG_proc, "sane_get_select_fd: enter\n");

Wyświetl plik

@ -59,7 +59,7 @@
VM656A, VM6586 VM656A, VM6586
update 2004/08/05, use of SANE_VALUE_SCAN_MODE_LINEART, _GRAY, and _COLOR, update 2004/08/05, use of SANE_VALUE_SCAN_MODE_LINEART, _GRAY, and _COLOR,
changed use of %d to %ld (when bytes values are displayed) changed use of %d to %ld (when bytes values are displayed)
update 2005/03/04, use of __unused__ update 2005/03/04, use of __sane_unused__
update 2005/07/29. Removed using teco_request_sense (dev) routine for VM3564 update 2005/07/29. Removed using teco_request_sense (dev) routine for VM3564
*/ */
@ -1669,7 +1669,7 @@ teco_scan (Teco_Scanner * dev)
/* SCSI sense handler. Callback for SANE. */ /* SCSI sense handler. Callback for SANE. */
static SANE_Status static SANE_Status
teco_sense_handler (int scsi_fd, unsigned char *result, void __unused__ *arg) teco_sense_handler (int scsi_fd, unsigned char *result, void __sane_unused__ *arg)
{ {
int asc, ascq, sensekey; int asc, ascq, sensekey;
int len; int len;
@ -2504,7 +2504,7 @@ do_cancel (Teco_Scanner * dev)
/* Sane entry points */ /* Sane entry points */
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
FILE *fp; FILE *fp;
char dev_name[PATH_MAX]; char dev_name[PATH_MAX];
@ -2551,7 +2551,7 @@ sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize)
} }
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, SANE_Bool __unused__ local_only) sane_get_devices (const SANE_Device *** device_list, SANE_Bool __sane_unused__ local_only)
{ {
Teco_Scanner *dev; Teco_Scanner *dev;
int i; int i;
@ -3341,7 +3341,7 @@ sane_read (SANE_Handle handle, SANE_Byte * buf, SANE_Int max_len,
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocking) sane_set_io_mode (SANE_Handle __sane_unused__ handle, SANE_Bool __sane_unused__ non_blocking)
{ {
SANE_Status status; SANE_Status status;
Teco_Scanner *dev = handle; Teco_Scanner *dev = handle;
@ -3368,7 +3368,7 @@ sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocki
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ * fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ * fd)
{ {
DBG (DBG_proc, "sane_get_select_fd: enter\n"); DBG (DBG_proc, "sane_get_select_fd: enter\n");

Wyświetl plik

@ -422,7 +422,7 @@ teco_identify_scanner (Teco_Scanner * dev)
/* SCSI sense handler. Callback for SANE. /* SCSI sense handler. Callback for SANE.
* These scanners never set asc or ascq. */ * These scanners never set asc or ascq. */
static SANE_Status static SANE_Status
teco_sense_handler (int __unused__ scsi_fd, unsigned char *result, void __unused__ *arg) teco_sense_handler (int __sane_unused__ scsi_fd, unsigned char *result, void __sane_unused__ *arg)
{ {
int sensekey; int sensekey;
int len; int len;
@ -1490,7 +1490,7 @@ do_cancel (Teco_Scanner * dev)
/* Sane entry points */ /* Sane entry points */
SANE_Status SANE_Status
sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize) sane_init (SANE_Int * version_code, SANE_Auth_Callback __sane_unused__ authorize)
{ {
FILE *fp; FILE *fp;
char dev_name[PATH_MAX]; char dev_name[PATH_MAX];
@ -1537,7 +1537,7 @@ sane_init (SANE_Int * version_code, SANE_Auth_Callback __unused__ authorize)
} }
SANE_Status SANE_Status
sane_get_devices (const SANE_Device *** device_list, SANE_Bool __unused__ local_only) sane_get_devices (const SANE_Device *** device_list, SANE_Bool __sane_unused__ local_only)
{ {
Teco_Scanner *dev; Teco_Scanner *dev;
int i; int i;
@ -2152,7 +2152,7 @@ sane_read (SANE_Handle handle, SANE_Byte * buf, SANE_Int max_len,
} }
SANE_Status SANE_Status
sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocking) sane_set_io_mode (SANE_Handle __sane_unused__ handle, SANE_Bool __sane_unused__ non_blocking)
{ {
SANE_Status status; SANE_Status status;
Teco_Scanner *dev = handle; Teco_Scanner *dev = handle;
@ -2179,7 +2179,7 @@ sane_set_io_mode (SANE_Handle __unused__ handle, SANE_Bool __unused__ non_blocki
} }
SANE_Status SANE_Status
sane_get_select_fd (SANE_Handle __unused__ handle, SANE_Int __unused__ * fd) sane_get_select_fd (SANE_Handle __sane_unused__ handle, SANE_Int __sane_unused__ * fd)
{ {
DBG (DBG_proc, "sane_get_select_fd: enter\n"); DBG (DBG_proc, "sane_get_select_fd: enter\n");

Wyświetl plik

@ -20,11 +20,11 @@
/* __unused tells the compiler a variable is unused, so the /* __unused tells the compiler a variable is unused, so the
* compiler doesn't spit a warning. */ * compiler doesn't spit a warning. */
#define __unused__ __attribute__((unused)) #define __sane_unused__ __attribute__((unused))
#else #else
#define __unused__ #define __sane_unused__
#endif #endif