From: Ben Pfaff Date: Thu, 5 May 2011 04:16:39 +0000 (-0700) Subject: intern: Fix GCC warning. X-Git-Tag: v0.7.9~322 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ff3ee9e59efa3a70841c23f1bdc35da74f5c6d18;p=pspp-builds.git intern: Fix GCC warning. Otherwise, GCC issues the following warning: intern.c:83: warning: comparison of distinct pointer types lacks a cast. --- diff --git a/src/libpspp/intern.c b/src/libpspp/intern.c index fe0e784c..fc31acf0 100644 --- a/src/libpspp/intern.c +++ b/src/libpspp/intern.c @@ -78,8 +78,9 @@ intern_new (const char *s) } static struct interned_string * -interned_string_from_string (const char *s) +interned_string_from_string (const char *s_) { + char (*s)[1] = (char (*)[1]) s_; struct interned_string *is = UP_CAST (s, struct interned_string, string); assert (is->ref_cnt > 0); return is;