[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
texinfo/makeinfo float.c,1.26,1.27
From: |
karl |
Subject: |
texinfo/makeinfo float.c,1.26,1.27 |
Date: |
Thu, 25 Mar 2004 01:20:20 +0100 |
Update of /cvsroot/texinfo/texinfo/makeinfo
In directory sheep:/tmp/cvs-serv10920
Modified Files:
float.c
Log Message:
avoid use of snprintf, which is not available on
all platforms.
Index: float.c
===================================================================
RCS file: /cvsroot/texinfo/texinfo/makeinfo/float.c,v
retrieving revision 1.26
retrieving revision 1.27
diff -C2 -d -r1.26 -r1.27
*** float.c 19 Mar 2004 16:26:45 -0000 1.26
--- float.c 25 Mar 2004 00:20:16 -0000 1.27
***************
*** 57,64 ****
{ /* Append the current float number. */
! char s[100];
! snprintf (s, 100, "%s%d", new->number,
! count_floats_of_type_in_chapter (text_expansion (type), new->number)
+ 1);
free (new->number);
new->number = xstrdup (s);
--- 57,66 ----
{ /* Append the current float number. */
! unsigned len = strlen (new->number) + 21; /* that's 64 bits */
! char *s = xmalloc (len + 1);
! sprintf (s, "%s%d", new->number,
! count_floats_of_type_in_chapter (text_expansion (type),
! new->number) + 1);
free (new->number);
new->number = xstrdup (s);
***************
*** 189,193 ****
{
int command_len = sizeof ("@ ") + strlen (command) + strlen
(float_type);
! char *list_command = xmalloc (command_len);
/* These are for the text following @listoffloats command.
--- 191,195 ----
{
int command_len = sizeof ("@ ") + strlen (command) + strlen
(float_type);
! char *list_command = xmalloc (command_len + 1);
/* These are for the text following @listoffloats command.
***************
*** 196,200 ****
cm_noindent ();
! snprintf (list_command, command_len, "@%s %s", command, float_type);
register_delayed_write (list_command);
free (list_command);
--- 198,202 ----
cm_noindent ();
! sprintf (list_command, "@%s %s", command, float_type);
register_delayed_write (list_command);
free (list_command);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- texinfo/makeinfo float.c,1.26,1.27,
karl <=
- Prev by Date:
texinfo ChangeLog,1.296,1.297 NEWS,1.22,1.23
- Next by Date:
texinfo/makeinfo index.c,1.21,1.22
- Previous by thread:
texinfo ChangeLog,1.296,1.297 NEWS,1.22,1.23
- Next by thread:
texinfo/makeinfo index.c,1.21,1.22
- Index(es):