Skip to content

Commit

Permalink
OXT-439: fix the broken logic
Browse files Browse the repository at this point in the history
Signed-off-by: Jed <lejosnej@ainfosec.com>
  • Loading branch information
jean-edouard committed Nov 23, 2015
1 parent 54b9a9b commit b66e572
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ gboolean ctxusb_daemon_get_device_info(CtxusbDaemonObject *this,
char *uuid = policy_get_sticky_uuid(IN_dev_id);
if (uuid != NULL) {
/* But it has an always-assign VM */
if (device->type | OPTICAL)
if (device->type & OPTICAL)
/* It's a CD drive */
*OUT_state = DEV_STATE_CD_ALWAYS;
else {
Expand All @@ -266,7 +266,7 @@ gboolean ctxusb_daemon_get_device_info(CtxusbDaemonObject *this,
*OUT_vm_assigned = g_strdup(uuid);
} else {
/* It doesn't have an always-assign VM, it's all free */
if (device->type | OPTICAL)
if (device->type & OPTICAL)
/* Unless it's a CD drive */
*OUT_state = DEV_STATE_CD_DOM0;
else
Expand Down

0 comments on commit b66e572

Please sign in to comment.