<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Aug 25, 2015 at 11:43 AM, Frediano Ziglio <span dir="ltr"><<a href="mailto:fziglio@redhat.com" target="_blank">fziglio@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">A logical and (&&) was used instead of a bit one (&).<br>
Was working just as is the only flag defined.<br>
<br>
Signed-off-by: Frediano Ziglio <<a href="mailto:fziglio@redhat.com">fziglio@redhat.com</a>><br>
---<br>
 server/red_record_qxl.c | 2 +-<br>
 server/red_replay_qxl.c | 2 +-<br>
 2 files changed, 2 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/server/red_record_qxl.c b/server/red_record_qxl.c<br>
index d96fb79..b35b462 100644<br>
--- a/server/red_record_qxl.c<br>
+++ b/server/red_record_qxl.c<br>
@@ -724,7 +724,7 @@ static void red_record_surface_cmd(FILE *fd, RedMemSlotInfo *slots, int group_id<br>
         fprintf(fd, "u.surface_create.height %d\n", qxl->u.surface_create.height);<br>
         fprintf(fd, "u.surface_create.stride %d\n", qxl->u.surface_create.stride);<br>
         size = qxl->u.surface_create.height * abs(qxl->u.surface_create.stride);<br>
-        if (qxl->flags && QXL_SURF_FLAG_KEEP_DATA) {<br>
+        if ((qxl->flags & QXL_SURF_FLAG_KEEP_DATA) != 0) {<br>
             write_binary(fd, "data", size,<br>
                 (uint8_t*)get_virt(slots, qxl->u.surface_create.data, size, group_id,<br>
                                    &error));<br>
diff --git a/server/red_replay_qxl.c b/server/red_replay_qxl.c<br>
index a010a58..5044adf 100644<br>
--- a/server/red_replay_qxl.c<br>
+++ b/server/red_replay_qxl.c<br>
@@ -1025,7 +1025,7 @@ static QXLSurfaceCmd *red_replay_surface_cmd(SpiceReplay *replay)<br>
         replay_fscanf(replay, "u.surface_create.height %d\n", &qxl->u.surface_create.height);<br>
         replay_fscanf(replay, "u.surface_create.stride %d\n", &qxl->u.surface_create.stride);<br>
         size = qxl->u.surface_create.height * abs(qxl->u.surface_create.stride);<br>
-        if (qxl->flags && QXL_SURF_FLAG_KEEP_DATA) {<br>
+        if ((qxl->flags & QXL_SURF_FLAG_KEEP_DATA) != 0) {<br>
             read_binary(replay, "data", &read_size, (uint8_t**)&qxl->u.surface_create.data, 0);<br>
             if (read_size != size) {<br>
                 spice_printerr("mismatch %ld != %ld", size, read_size);<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.4.3<br>
<br>
_______________________________________________<br>
Spice-devel mailing list<br>
<a href="mailto:Spice-devel@lists.freedesktop.org">Spice-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/spice-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/spice-devel</a><br>
</font></span></blockquote></div><br><br clear="all"></div><div class="gmail_extra">ACK!<br></div><div class="gmail_extra">-- <br><div class="gmail_signature"><div dir="ltr">Fabiano Fidêncio<br></div></div>
</div></div>