Presumably you're registering a callback for the RXFLAG event (to respond to the arrival of a specific character). The issue is tied to the underlying Windows API. In order to get Windows to notify the arrival of an event character, we have to call
SetCommState Win API function which sets a whole slew of port options (refer to the DCB structure, and the EvtChar member). Despite the fact that we initialize the structure with all the current port settings, it still apprently effects some changes. If you are not enabling the RXFLAG event, then SetCommState does not need to be called; calling SetCommMask is sufficient.
So unfortunately, no, InstallComCallback cannot just set the mask or specifically what it needs and leave everything else alone, because one of the things it needs to change is bundled up with a bunch of other settings in the DCB structure.
Hope this helps.
Mert A.
National Instruments