Prevents a warning here about const char* -> char* assignment tossing
away the qualifier. The warning is still there for BSDoptarg, but that
is specified by getopt.h to not be const.

Also fix a stray whitespace error.

Signed-off-by: Ben Boeckel <maths...@gmail.com>
---
 compat/getopt.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/compat/getopt.c b/compat/getopt.c
index a93f368..03ad9e8 100644
--- a/compat/getopt.c
+++ b/compat/getopt.c
@@ -52,7 +52,7 @@ char  *BSDoptarg;             /* argument associated with 
option */
 int
 BSDgetopt(int nargc, char *const *nargv, const char *ostr)
 {
-       static char *place = EMSG;              /* option letter processing */
+       static const char *place = EMSG;        /* option letter processing */
        char *oli;                              /* option letter list index */
 
        if (ostr == NULL)
@@ -105,7 +105,7 @@ BSDgetopt(int nargc, char *const *nargv, const char *ostr)
                                    __progname, BSDoptopt);
                        return (BADCH);
                }
-               else                            /* white space */
+               else                            /* white space */
                        BSDoptarg = nargv[BSDoptind];
                place = EMSG;
                ++BSDoptind;
-- 
2.3.0


------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk
_______________________________________________
tmux-users mailing list
tmux-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/tmux-users

Reply via email to