svn commit: r229811 - stable/9/contrib/less

Dimitry Andric dim at FreeBSD.org
Sun Jan 8 13:51:10 UTC 2012


Author: dim
Date: Sun Jan  8 13:51:09 2012
New Revision: 229811
URL: http://svn.freebsd.org/changeset/base/229811

Log:
  MFC r229196:
  
  Redo r228645, but instead of casting away const conversion warnings in
  contrib/less, add a few const qualifiers in the right places.
  
  Suggested by:	das

Modified:
  stable/9/contrib/less/command.c
  stable/9/contrib/less/prompt.c
Directory Properties:
  stable/9/contrib/less/   (props changed)

Modified: stable/9/contrib/less/command.c
==============================================================================
--- stable/9/contrib/less/command.c	Sun Jan  8 13:34:00 2012	(r229810)
+++ stable/9/contrib/less/command.c	Sun Jan  8 13:51:09 2012	(r229811)
@@ -105,7 +105,7 @@ cmd_exec()
 start_mca(action, prompt, mlist, cmdflags)
 	int action;
 	char *prompt;
-	void *mlist;
+	void constant *mlist;
 	int cmdflags;
 {
 	mca = action;
@@ -686,7 +686,7 @@ make_display()
 	static void
 prompt()
 {
-	register char *p;
+	register char constant *p;
 
 	if (ungot != NULL)
 	{

Modified: stable/9/contrib/less/prompt.c
==============================================================================
--- stable/9/contrib/less/prompt.c	Sun Jan  8 13:34:00 2012	(r229810)
+++ stable/9/contrib/less/prompt.c	Sun Jan  8 13:51:09 2012	(r229811)
@@ -394,9 +394,9 @@ protochar(c, where, iseditproto)
  * where to resume parsing the string.
  * We must keep track of nested IFs and skip them properly.
  */
-	static char *
+	static char constant *
 skipcond(p)
-	register char *p;
+	register char constant *p;
 {
 	register int iflevel;
 
@@ -452,9 +452,9 @@ skipcond(p)
 /*
  * Decode a char that represents a position on the screen.
  */
-	static char *
+	static char constant *
 wherechar(p, wp)
-	char *p;
+	char constant *p;
 	int *wp;
 {
 	switch (*p)
@@ -478,10 +478,10 @@ wherechar(p, wp)
  */
 	public char *
 pr_expand(proto, maxwidth)
-	char *proto;
+	char constant *proto;
 	int maxwidth;
 {
-	register char *p;
+	register char constant *p;
 	register int c;
 	int where;
 


More information about the svn-src-stable-9 mailing list