X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=src%2FSFont.xs;h=5c5136b2ebdb80abd656d4857265db683a35ab5b;hb=24379be6145d8b1f519155219cdf6a96710d40b1;hp=2839a6747e06887a87d6af38370cd0f7a80dba37;hpb=039b5b1f53719b8ef34c1e6b58e86c9d4a7b5bc9;p=sdlgit%2FSDL_perl.git diff --git a/src/SFont.xs b/src/SFont.xs index 2839a67..5c5136b 100644 --- a/src/SFont.xs +++ b/src/SFont.xs @@ -225,7 +225,7 @@ void SFont_InternalInput( SDL_Surface *Dest, SFont_FontInfo *Font, int x, int y, if ((ch=='\b')&&(strlen(text)>0)) text[strlen(text)-1]='\0'; else if (ch!='\b') - sprintf(text,"%s%c",text,ch); + sprintf(text+strlen(text),"%c",ch); if (SFont_TextWidth2(Font,text)>PixelWidth) text[strlen(text)-1]='\0'; SDL_BlitSurface( Back, NULL, Dest, &rect); SFont_PutString2(Dest, Font, x, y, text);