From 04a62017bc61cc65ab5f408a69b4f5a6edece8d0 Mon Sep 17 00:00:00 2001 From: Michael Hunold Date: Wed, 10 Sep 2003 11:05:57 +0000 Subject: Make sure void* arguments get converted in two steps: first cast to long, then cast to the destination type (mostly int) to avoid endianess bugs --- linux/drivers/media/dvb/dvb-core/dvb_net.c | 2 +- linux/drivers/media/dvb/ttpci/budget-patch.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'linux') diff --git a/linux/drivers/media/dvb/dvb-core/dvb_net.c b/linux/drivers/media/dvb/dvb-core/dvb_net.c index db9c6f27e..4bbca09cd 100644 --- a/linux/drivers/media/dvb/dvb-core/dvb_net.c +++ b/linux/drivers/media/dvb/dvb-core/dvb_net.c @@ -605,7 +605,7 @@ static int dvb_net_do_ioctl(struct inode *inode, struct file *file, case NET_REMOVE_IF: if (!capable(CAP_SYS_ADMIN)) return -EPERM; - return dvb_net_remove_if(dvbnet, (long) parg); + return dvb_net_remove_if(dvbnet, (int) (long) parg); default: return -EINVAL; } diff --git a/linux/drivers/media/dvb/ttpci/budget-patch.c b/linux/drivers/media/dvb/ttpci/budget-patch.c index 2673d6042..14d3e56d7 100644 --- a/linux/drivers/media/dvb/ttpci/budget-patch.c +++ b/linux/drivers/media/dvb/ttpci/budget-patch.c @@ -150,7 +150,7 @@ int budget_patch_diseqc_ioctl (struct dvb_frontend *fe, unsigned int cmd, void * } case FE_DISEQC_SEND_BURST: - av7110_send_diseqc_msg (budget, 0, NULL, (int) arg); + av7110_send_diseqc_msg (budget, 0, NULL, (int) (long) arg); break; default: -- cgit v1.2.3