From: Ilya Tocar Date: Wed, 18 Feb 2015 13:33:43 +0000 (+0000) Subject: target.c (gomp_load_plugin_for_device): Use const char * instead of char * for variab... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=196904d81317875a5ba0d89693384e6da33be785;p=gcc.git target.c (gomp_load_plugin_for_device): Use const char * instead of char * for variables holding dlerror return values. libgomp/ * target.c (gomp_load_plugin_for_device): Use const char * instead of char * for variables holding dlerror return values. (DLSYM_OPT): Ditto. From-SVN: r220789 --- diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index 8477c3bf464..96f3ca3ad87 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,9 @@ +2015-02-18 Ilya Tocar + + * target.c (gomp_load_plugin_for_device): Use const char * instead of + char * for variables holding dlerror return values. + (DLSYM_OPT): Ditto. + 2015-02-17 Thomas Schwinge * libgomp-plugin.c (GOMP_PLUGIN_debug): Fix typo. diff --git a/libgomp/target.c b/libgomp/target.c index 73e757a9ec1..50baa4d1319 100644 --- a/libgomp/target.c +++ b/libgomp/target.c @@ -919,7 +919,7 @@ static bool gomp_load_plugin_for_device (struct gomp_device_descr *device, const char *plugin_name) { - char *err = NULL, *last_missing = NULL; + const char *err = NULL, *last_missing = NULL; int optional_present, optional_total; /* Clear any existing error. */ @@ -947,7 +947,7 @@ gomp_load_plugin_for_device (struct gomp_device_descr *device, #define DLSYM_OPT(f, n) \ do \ { \ - char *tmp_err; \ + const char *tmp_err; \ device->f##_func = dlsym (plugin_handle, "GOMP_OFFLOAD_" #n); \ tmp_err = dlerror (); \ if (tmp_err == NULL) \