epics-extensions / medm

Motif Editor and Display Manager
Other
11 stars 9 forks source link

Ubuntu xm-nuser-fix #4

Closed runchman closed 3 years ago

runchman commented 4 years ago

On Ubuntu 16.04, 64 bit:

When calling XtVaGetValues() to retrieve the XmNuserData field, the returned value is of whatever size an XtPointer is.

Passing the address of an int variable into this routine caused segfault, as the compiler treats an int as 32 bits, not the 64 bits XtVaGetValues is expecting.

Fixed by passing in a generic pointer type and casting to an int after the call.