Skip to content

Commit

Permalink
Merge pull request #5 from d3m3vilurr/fix-with-homebrew
Browse files Browse the repository at this point in the history
Fix stuck with homebrew
  • Loading branch information
frangarcj authored Jan 16, 2017
2 parents fcd6fe0 + 63e9ab6 commit fe61978
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions blit.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,7 @@
*/
#include <psp2/types.h>
#include <psp2/display.h>

#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
#include <string.h>
#include <psp2/kernel/clib.h>

#include "blit.h"

Expand Down Expand Up @@ -150,7 +146,7 @@ int blit_string(int sx,int sy,const char *msg)

int blit_string_ctr(int sy,const char *msg)
{
int sx = 960/2-strlen(msg)*(16/2);
int sx = 960/2-sceClibStrnlen(msg, 512)*(16/2);
return blit_string(sx,sy,msg);
}

Expand All @@ -160,7 +156,7 @@ int blit_stringf(int sx, int sy, const char *msg, ...)
char string[512];

va_start(list, msg);
vsprintf(string, msg, list);
sceClibVsnprintf(string, 512, msg, list);
va_end(list);

return blit_string(sx, sy, string);
Expand Down

0 comments on commit fe61978

Please sign in to comment.