sim: mips: tweak buffer sign
authorMike Frysinger <vapier@gentoo.org>
Tue, 15 Jun 2021 04:40:17 +0000 (00:40 -0400)
committerMike Frysinger <vapier@gentoo.org>
Wed, 16 Jun 2021 05:53:09 +0000 (01:53 -0400)
This model uses unsigned char buffers, but this temporary pointer is
declared as signed.  Switch it to unsigned since it's just a temporary
variable to hold the new pointer.

sim/mips/ChangeLog
sim/mips/dv-tx3904sio.c

index 1e57fe54326ea41bceda20a6ad29bf7379039a42..28a33c78995a7678b80ea489a84aab5c772513c2 100644 (file)
@@ -1,3 +1,8 @@
+2021-06-16  Mike Frysinger  <vapier@gentoo.org>
+
+       * dv-tx3904sio.c (tx3904sio_fifo_push): Change next_buf to
+       unsigned_1.
+
 2021-06-16  Mike Frysinger  <vapier@gentoo.org>
 
        * dv-tx3904irc.c (tx3904irc_io_write_buffer): Initialize
index c81b2dd3a5e79b1711c5de407a5354e0a7ca27e3..d447014014ccee44c65acf80604bf9ef49bbfc79 100644 (file)
@@ -582,7 +582,7 @@ tx3904sio_fifo_push(struct hw* me, struct tx3904sio_fifo* fifo, char it)
   if(fifo->size == fifo->used) /* full */
     {
       int next_size = fifo->size * 2 + 16;
-      char* next_buf = zalloc(next_size);
+      unsigned_1* next_buf = zalloc(next_size);
       memcpy(next_buf, fifo->buffer, fifo->used);
 
       if(fifo->buffer != NULL) free(fifo->buffer);