Advertisement
Guest User

Untitled

a guest
Oct 5th, 2011
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. diff --git a/firmware/font.c b/firmware/font.c
  2. index f00ff0e..7d28368 100644
  3. --- a/firmware/font.c
  4. +++ b/firmware/font.c
  5. @@ -594,14 +614,17 @@ struct font* font_get(int font)
  6. return &sysfont;
  7.  
  8. while (1) {
  9. - struct buflib_alloc_data *alloc = core_get_data(buflib_allocations[font]);
  10. - pf = &alloc->font;
  11. - if (pf && pf->height)
  12. - return pf;
  13. + if (buflib_allocations[font] > 0)
  14. + {
  15. + struct buflib_alloc_data *alloc = core_get_data(buflib_allocations[font]);
  16. + pf = &alloc->font;
  17. + if (pf && pf->height)
  18. + return pf;
  19. + }
  20. if (--font < 0)
  21. return &sysfont;
  22. }
  23. -}
  24. +}
  25.  
  26. static int pf_to_handle(struct font* pf)
  27. {
  28.  
  29.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement