[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2] Fix error: array subscript has type 'char'


  • To: Manuel Bouyer <bouyer@xxxxxxxxxx>, <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • Date: Wed, 27 Jan 2021 19:30:52 +0000
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+tv+nZ6bBfxFKLATqd1N8XdpA68D6gsfp0skGPdsesA=; b=CauAo47SHwadfWU7fC+dR0pQYmdBTbUDXJE9PekWsyryFFbZ+pj+TNOZWgqnYoNISS+yQ9Zs61/J5C6H3KdMf6bgzcNKioN/aTS7ALEFOuVl0EprEvrDtmgk/Fc/oQ0+tE7isRUskTi8Sx0pNdPMmUabM1nHo6fb7Wt1jahzY9IMtn7UuGypbdMSm6kNkXGWCHtJ+N1aZFepVg8b3snf/0e+pB136X1N8SW1odyuorI3JysmX0buppSUQz8mtdkJiDnMNVvtw81CPNQauj+OZ7hLZBO2csASbWgncroRPaP2hwIugvJDsySdPDADzQJsS5Ijo4aLhv/PT6wHDpkVfQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=g00c+lrPufVxOgbX8LdtjGwm7uFX/iKE8A+ApIQIYx74QFIbA63J/h6qhGvCd/crFbdLOV9njjWqKUdj3hgaLuBAEciey+o6JHBvY2iGGwe7ShsFpHAAuxGMWrVQmxbe5MVXJyKEtrPtuKGjCHWpqEKb0lkonAxSzMY1YBkS1sO0ce4Oxp5s3RJZkXrIIJP4zv2hkK+CmSwJLYVKsuzHt/1M5rXsCyv4ggYBIjgNYKUNLvC5g0tGSpow1ZSL3ceZFOag2Wn3ui07Xx8b6Re4zefZTl8zOh8gzWOlHDzJQSJKWKKZ+ETacXL1L/6+7j6oKIxWLAtxLiUA/cycbFUsog==
  • Authentication-results: esa3.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • Delivery-date: Wed, 27 Jan 2021 19:31:08 +0000
  • Ironport-sdr: vg3Fakddlt8uuomWlSXtiVrTRkt7J4CgItjyZlNz3N3OyEsNsSmd4y9X93noNdtyMvcFDJXkaw C0LMGfs51bXahPjZlwzNeu2EYyibkpjBjzFrj15ykcr+FjE/jvSmuhJ4NOqR/GCVatiP9Mt/b+ lPsE/7MrP9U/B1NOhziJ5Z3pZN28wFXpmpiBZO7nUZyLusozwYCMIJ0L3kK+HATSZMzruVYGs1 kRB8orrZERO/T2fNzmloDNdahRLsbKkS6cbqSVl3l+tZDWb7FlaIpwcCDv8nQXca9AnIijEWFm 5rU=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 26/01/2021 22:47, Manuel Bouyer wrote:
> Use unsigned char variable, or cast to (unsigned char), for
> tolower()/islower() and friends. Fix compiler error
> array subscript has type 'char' [-Werror=char-subscripts]
>
> Signed-off-by: Manuel Bouyer <bouyer@xxxxxxxxxx>
> Reviewed-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
> Release-Acked-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
> ---
>  tools/libs/light/libxl_qmp.c | 2 +-
>  tools/xentrace/xentrace.c    | 2 +-
>  xen/tools/symbols.c          | 4 ++--

Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

This is totally ugly, but it is a well known totally ugly corner case of
C.  Non-freestanding bits have to play by C's rules to be compatible.

~Andrew



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.