mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-30 11:50:28 +02:00
* ports.c (scm_ungetc): Cast value to unsigned char ptr before
storing in putback_buf. (scm_unread_string): Substituted SCM_ROCHARS for SCM_ROUCHARS.
This commit is contained in:
parent
c507087791
commit
c357d54673
1 changed files with 3 additions and 2 deletions
|
@ -969,7 +969,8 @@ scm_ungetc (int c, SCM port)
|
|||
{
|
||||
if (pt->putback_buf == NULL)
|
||||
{
|
||||
pt->putback_buf = (char *) malloc (SCM_INITIAL_PUTBACK_BUF_SIZE);
|
||||
pt->putback_buf
|
||||
= (unsigned char *) malloc (SCM_INITIAL_PUTBACK_BUF_SIZE);
|
||||
if (pt->putback_buf == NULL)
|
||||
scm_memory_error ("scm_ungetc");
|
||||
pt->putback_buf_size = SCM_INITIAL_PUTBACK_BUF_SIZE;
|
||||
|
@ -1081,7 +1082,7 @@ SCM_DEFINE (scm_unread_string, "unread-string", 2, 0, 0,
|
|||
else
|
||||
SCM_VALIDATE_OPINPORT (2,port);
|
||||
|
||||
scm_ungets (SCM_ROUCHARS (str), SCM_LENGTH (str), port);
|
||||
scm_ungets (SCM_ROCHARS (str), SCM_LENGTH (str), port);
|
||||
|
||||
return str;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue