From 7cb1e19ce91dc64520925e61677a0ac48899fc57 Mon Sep 17 00:00:00 2001 From: Matthew Fernandez <matthew.fernandez@gmail.com> Date: Thu, 3 Jun 2021 17:19:13 -0700 Subject: [PATCH] =?utf8?q?remove=20unnecessary=20strdup=20casts=20in=20Lef?= =?utf8?q?ty=E2=80=99s=20yylex?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit strdup already returns a char*. --- cmd/lefty/dot2l/dotlex.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/lefty/dot2l/dotlex.c b/cmd/lefty/dot2l/dotlex.c index c404913ad..a3de2431f 100644 --- a/cmd/lefty/dot2l/dotlex.c +++ b/cmd/lefty/dot2l/dotlex.c @@ -84,14 +84,14 @@ int yylex (void) { /* scan quoted strings */ if (lexptr[0] == '\"') { lexptr = quoted_string (lexptr); - yylval.s = (char *) strdup (lexbuf); + yylval.s = strdup (lexbuf); return T_id; } /* scan html strings */ if (lexptr[0] == '<') { lexptr = html_string (lexptr); - yylval.s = (char *) strdup (lexbuf); + yylval.s = strdup (lexbuf); return T_id; } -- 2.40.0