test-qcdm-serial-port: fix warnings with -Wsign-compare

test-qcdm-serial-port.c: In function 'wait_for_child':
  test-qcdm-serial-port.c:57:52: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
           if (d->child && (now.tv_sec - start.tv_sec > timeout)) {
                                                      ^
This commit is contained in:
Aleksander Morgado
2020-05-19 13:44:23 +02:00
parent 71d8bb2ec8
commit c7dee320c0
+1 -1
View File
@@ -54,7 +54,7 @@ wait_for_child (TestData *d, guint32 timeout)
status = 0;
ret = waitpid (d->child, &status, WNOHANG);
g_get_current_time (&now);
if (d->child && (now.tv_sec - start.tv_sec > timeout)) {
if (d->child && (now.tv_sec - start.tv_sec > (glong)timeout)) {
/* Kill it */
if (g_test_verbose ())
g_message ("Killing running child process %d", d->child);