svn commit: r229196 - head/contrib/less
Dimitry Andric
dim at FreeBSD.org
Sun Jan 1 20:13:03 UTC 2012
Author: dim
Date: Sun Jan 1 20:13:02 2012
New Revision: 229196
URL: http://svn.freebsd.org/changeset/base/229196
Log:
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
MFC after: 1 week
Modified:
head/contrib/less/command.c
head/contrib/less/prompt.c
Modified: head/contrib/less/command.c
==============================================================================
--- head/contrib/less/command.c Sun Jan 1 20:09:05 2012 (r229195)
+++ head/contrib/less/command.c Sun Jan 1 20:13:02 2012 (r229196)
@@ -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: head/contrib/less/prompt.c
==============================================================================
--- head/contrib/less/prompt.c Sun Jan 1 20:09:05 2012 (r229195)
+++ head/contrib/less/prompt.c Sun Jan 1 20:13:02 2012 (r229196)
@@ -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-all
mailing list