summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2009-03-22 06:38:02 +0000
committerGuy Harris <guy@alum.mit.edu>2009-03-22 06:38:02 +0000
commit6f059e8cb7877efe7c87bbd3c6ee3b6737db950f (patch)
treea27451a98daf585dfa2d4ad90423876e85954d3e
parent7c6e2155cc01e650987e3adc5529d16c27ad5816 (diff)
downloadwireshark-6f059e8cb7877efe7c87bbd3c6ee3b6737db950f.tar.gz
In Solaris, the second argument to dladdr() is just a void *, not a
const void *. svn path=/trunk/; revision=27813
-rw-r--r--capinfos.c3
-rw-r--r--dftest.c3
-rw-r--r--editcap.c3
-rw-r--r--epan/filesystem.c2
-rw-r--r--epan/filesystem.h2
-rw-r--r--gtk/main.c3
-rw-r--r--rawshark.c3
-rw-r--r--tshark.c3
8 files changed, 8 insertions, 14 deletions
diff --git a/capinfos.c b/capinfos.c
index 8d09fcdf9e..777cc0fa56 100644
--- a/capinfos.c
+++ b/capinfos.c
@@ -302,8 +302,7 @@ main(int argc, char *argv[])
#ifdef HAVE_PLUGINS
/* Register wiretap plugins */
- if ((init_progfile_dir_error = init_progfile_dir(argv[0],
- (const void *)main))) {
+ if ((init_progfile_dir_error = init_progfile_dir(argv[0], (void *)main))) {
g_warning("capinfos: init_progfile_dir(): %s", init_progfile_dir_error);
g_free(init_progfile_dir_error);
} else {
diff --git a/dftest.c b/dftest.c
index 7fbadd8bc7..eba59b0ea4 100644
--- a/dftest.c
+++ b/dftest.c
@@ -75,8 +75,7 @@ main(int argc, char **argv)
/*
* Attempt to get the pathname of the executable file.
*/
- init_progfile_dir_error = init_progfile_dir(argv[0],
- (const void *)main);
+ init_progfile_dir_error = init_progfile_dir(argv[0], (void *)main);
if (init_progfile_dir_error != NULL) {
fprintf(stderr, "dftest: Can't get pathname of dftest program: %s.\n",
init_progfile_dir_error);
diff --git a/editcap.c b/editcap.c
index 9f2fb28d57..250730c7a8 100644
--- a/editcap.c
+++ b/editcap.c
@@ -424,8 +424,7 @@ main(int argc, char *argv[])
#ifdef HAVE_PLUGINS
/* Register wiretap plugins */
- if ((init_progfile_dir_error = init_progfile_dir(argv[0],
- (const void *)main))) {
+ if ((init_progfile_dir_error = init_progfile_dir(argv[0], (void *)main))) {
g_warning("capinfos: init_progfile_dir(): %s", init_progfile_dir_error);
g_free(init_progfile_dir_error);
} else {
diff --git a/epan/filesystem.c b/epan/filesystem.c
index 79312d3a05..dbf5e04f71 100644
--- a/epan/filesystem.c
+++ b/epan/filesystem.c
@@ -249,7 +249,7 @@ init_progfile_dir(const char *arg0
#ifdef _WIN32
_U_
#endif
-, const void *main_addr
+, void *main_addr
#if defined(_WIN32) || !defined(DLADDR_FINDS_EXECUTABLE_PATH)
_U_
#endif
diff --git a/epan/filesystem.h b/epan/filesystem.h
index 01c2a60d3e..96adeb7425 100644
--- a/epan/filesystem.h
+++ b/epan/filesystem.h
@@ -36,7 +36,7 @@
* and save it for future use. Returns NULL on success, and a
* g_mallocated string containing an error on failure.
*/
-extern char *init_progfile_dir(const char *arg0, const void *main_addr);
+extern char *init_progfile_dir(const char *arg0, void *main_addr);
/*
* Get the directory in which the program resides.
diff --git a/gtk/main.c b/gtk/main.c
index 14a96ac837..d763aa87f1 100644
--- a/gtk/main.c
+++ b/gtk/main.c
@@ -1808,8 +1808,7 @@ main(int argc, char *argv[])
/*
* Attempt to get the pathname of the executable file.
*/
- init_progfile_dir_error = init_progfile_dir(argv[0],
- (const void *)main);
+ init_progfile_dir_error = init_progfile_dir(argv[0], (void *)main);
/* initialize the funnel mini-api */
initialize_funnel_ops();
diff --git a/rawshark.c b/rawshark.c
index 5b3d07af23..f1f31c125e 100644
--- a/rawshark.c
+++ b/rawshark.c
@@ -460,8 +460,7 @@ main(int argc, char *argv[])
/*
* Attempt to get the pathname of the executable file.
*/
- init_progfile_dir_error = init_progfile_dir(argv[0],
- (const void *)main);
+ init_progfile_dir_error = init_progfile_dir(argv[0], (void *)main);
if (init_progfile_dir_error != NULL) {
fprintf(stderr, "rawshark: Can't get pathname of rawshark program: %s.\n",
init_progfile_dir_error);
diff --git a/tshark.c b/tshark.c
index 688b0a9836..bf30086cce 100644
--- a/tshark.c
+++ b/tshark.c
@@ -773,8 +773,7 @@ main(int argc, char *argv[])
/*
* Attempt to get the pathname of the executable file.
*/
- init_progfile_dir_error = init_progfile_dir(argv[0],
- (const void *)main);
+ init_progfile_dir_error = init_progfile_dir(argv[0], (void *)main);
if (init_progfile_dir_error != NULL) {
fprintf(stderr, "tshark: Can't get pathname of tshark program: %s.\n",
init_progfile_dir_error);