mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-06 17:18:32 +00:00
Change return type of strptime from const char* to char*.
const char* was wrong and nonstandard.
This commit is contained in:
parent
b4b4fb871e
commit
f0cefaccae
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=39113
|
@ -143,7 +143,7 @@ void tzset __P((void));
|
|||
#endif /* not ANSI */
|
||||
|
||||
#if !defined(_ANSI_SOURCE) && !defined(_POSIX_SOURCE)
|
||||
const char *strptime __P((const char *, const char *, struct tm *));
|
||||
char *strptime __P((const char *, const char *, struct tm *));
|
||||
char *timezone __P((int, int));
|
||||
void tzsetwall __P((void));
|
||||
time_t timelocal __P((struct tm * const));
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
.\"
|
||||
.\" $Id$
|
||||
.\" $Id: strptime.3,v 1.1 1997/08/09 15:43:54 joerg Exp $
|
||||
.\" "
|
||||
.Dd May 8, 1997
|
||||
.Dt STRPTIME 3
|
||||
|
@ -33,7 +33,7 @@
|
|||
.Nd parse date and time string
|
||||
.Sh SYNOPSIS
|
||||
.Fd #include <time.h>
|
||||
.Ft const char *
|
||||
.Ft char *
|
||||
.Fn strptime "const char *buf" "const char *format" "struct tm *timeptr"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
|
|
|
@ -53,7 +53,7 @@
|
|||
|
||||
#ifdef LIBC_RCS
|
||||
static const char rcsid[] =
|
||||
"$Id: strptime.c,v 1.2 1997/08/09 15:43:56 joerg Exp $";
|
||||
"$Id: strptime.c,v 1.3 1997/08/13 13:11:53 ache Exp $";
|
||||
#endif
|
||||
|
||||
#ifndef lint
|
||||
|
@ -71,7 +71,7 @@ static char sccsid[] = "@(#)strptime.c 0.1 (Powerdog) 94/03/27";
|
|||
|
||||
#define asizeof(a) (sizeof (a) / sizeof ((a)[0]))
|
||||
|
||||
const char *
|
||||
char *
|
||||
strptime(const char *buf, const char *fmt, struct tm *tm)
|
||||
{
|
||||
char c;
|
||||
|
@ -345,5 +345,5 @@ strptime(const char *buf, const char *fmt, struct tm *tm)
|
|||
}
|
||||
}
|
||||
|
||||
return buf;
|
||||
return (char *)buf;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue