summaryrefslogtreecommitdiff
path: root/hw/dmx/input
diff options
context:
space:
mode:
authorAdam Jackson <ajax@redhat.com>2011-01-20 18:59:39 -0500
committerAdam Jackson <ajax@redhat.com>2011-01-20 21:03:42 -0500
commit7a08f9abef7219fabdab8d1d49e8d3afb042e36a (patch)
treed29138fe5c025d9992948c496c807f6d153cd36f /hw/dmx/input
parentffd323b7c0212ed9b348e51cd9b36363d7c4d1f2 (diff)
dmx: warning fixes
dmxinputinit.c: In function ‘dmxBlockHandler’: dmxinputinit.c:610:44: warning: cast from pointer to integer of different size dmxinputinit.c: In function ‘dmxWakeupHandler’: dmxinputinit.c:637:41: warning: cast from pointer to integer of different size dmxinputinit.c: In function ‘dmxInputInit’: dmxinputinit.c:1041:36: warning: cast to pointer from integer of different size Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
Diffstat (limited to 'hw/dmx/input')
-rw-r--r--hw/dmx/input/dmxinputinit.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/hw/dmx/input/dmxinputinit.c b/hw/dmx/input/dmxinputinit.c
index 6fc11cd0d..5cbd620c9 100644
--- a/hw/dmx/input/dmxinputinit.c
+++ b/hw/dmx/input/dmxinputinit.c
@@ -607,7 +607,7 @@ static void dmxCollectAll(DMXInputInfo *dmxInput)
static void dmxBlockHandler(pointer blockData, OSTimePtr pTimeout,
pointer pReadMask)
{
- DMXInputInfo *dmxInput = &dmxInputs[(int)blockData];
+ DMXInputInfo *dmxInput = &dmxInputs[(uintptr_t)blockData];
static unsigned long generation = 0;
if (generation != serverGeneration) {
@@ -634,7 +634,7 @@ static void dmxSwitchReturn(pointer p)
static void dmxWakeupHandler(pointer blockData, int result, pointer pReadMask)
{
- DMXInputInfo *dmxInput = &dmxInputs[(int)blockData];
+ DMXInputInfo *dmxInput = &dmxInputs[(uintptr_t)blockData];
int i;
if (dmxInput->vt_switch_pending) {
@@ -1036,9 +1036,8 @@ void dmxInputInit(DMXInputInfo *dmxInput)
dmxInput->processInputEvents = dmxProcessInputEvents;
dmxInput->detached = False;
- RegisterBlockAndWakeupHandlers(dmxBlockHandler,
- dmxWakeupHandler,
- (void *)dmxInput->inputIdx);
+ RegisterBlockAndWakeupHandlers(dmxBlockHandler, dmxWakeupHandler,
+ (void *)(uintptr_t)dmxInput->inputIdx);
}
static void dmxInputFreeLocal(DMXLocalInputInfoRec *local)