From: Matthew Fernandez Date: Sat, 30 May 2020 01:25:53 +0000 (-0700) Subject: mark gvplugin_api input as const X-Git-Tag: 2.44.1~16 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=0f45569ae89d11ed3b25a9ab8d3972383e5ce890;p=graphviz mark gvplugin_api input as const --- diff --git a/lib/gvc/gvcproc.h b/lib/gvc/gvcproc.h index 7210a50dc..826ce3fb6 100644 --- a/lib/gvc/gvcproc.h +++ b/lib/gvc/gvcproc.h @@ -33,7 +33,7 @@ gvplugin_installed_t * typeptr); extern gvplugin_available_t *gvplugin_load(GVC_t * gvc, api_t api, const char *type); extern gvplugin_library_t *gvplugin_library_load(GVC_t *gvc, char *path); - extern api_t gvplugin_api(char *str); + extern api_t gvplugin_api(const char *str); extern char * gvplugin_api_name(api_t api); extern void gvplugin_write_status(GVC_t * gvc); extern char *gvplugin_list(GVC_t * gvc, api_t api, const char *str); diff --git a/lib/gvc/gvplugin.c b/lib/gvc/gvplugin.c index c439ea43a..99b98b1b2 100644 --- a/lib/gvc/gvplugin.c +++ b/lib/gvc/gvplugin.c @@ -56,7 +56,7 @@ static char *api_names[] = { APIS }; /* "render", "layout", ... */ #undef ELEM /* translate a string api name to its type, or -1 on error */ -api_t gvplugin_api(char *str) +api_t gvplugin_api(const char *str) { int api;