summaryrefslogtreecommitdiff
path: root/apps/plugins/text_viewer/tv_text_processor.c (follow)
Commit message (Collapse)AuthorAge
* text_viewer plugin: Fix two out-of-bounds buffer accessesThomas Jarosch2014-12-20
| | | | | | | | | | | | | | | | | | | | | Test code: -------------- int main(void) { static unsigned short extra_spaces[] = { 0, 0x3000 }; return sizeof(extra_spaces); } -------------- -> returns four instead of two. cppcheck reported: [rockbox/apps/plugins/text_viewer/tv_text_processor.c:180]: (error) Array 'break_chars[27]' acces sed at index 53, which is out of bounds. [rockbox/apps/plugins/text_viewer/tv_text_processor.c:195]: (error) Array 'extra_spaces[2]' acces sed at index 3, which is out of bounds. Change-Id: I66c305cc5c99e59e7c8e0aa9c86cecbe293ff037
* FS#12273 - use buflib for font storage. thanks to the testers :)Jonathan Gordon2011-09-24
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30589 a1c6a512-1295-4272-9138-f99709370657
* text viewer: reworks screen access logics and some bugs fix.Yoshihisa Uchida2010-06-26
| | | | | | | | | | - screen access logics separte from tv_window. (new tv_display.[ch]) - using multi screen api. - (bug fix) the head of the each line is not normally displayed when the alignment is RIGHT. - (bug fix) unnecessary blank line is not displayed. (a part of FS#11400). - (bug fix) the order by which callback functions were called was not correct. (FIFO->FILO) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27138 a1c6a512-1295-4272-9138-f99709370657
* text_viewer: rename preference values.Yoshihisa Uchida2010-06-24
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27106 a1c6a512-1295-4272-9138-f99709370657
* FS#11399 by me: fix r26998 for text_viewerRafaël Carré2010-06-23
| | | | | | | | | | | | | | | | | Restore the old behaviour: - preferences must be read-write for tv_preferences.c , read-only for all other modules -> use pointer to const struct - init functions must get the plugin buffer + its size as arguments for easily adding new functions -> use pointer to buffer pointer and size to make allocation easier - preferences meaning is private to each file and must not be known by tv_preferences.c -> move tv_check_header_and_footer() back in tv_window.c; also avoid chaining 3 times the callbacks by calling tv_set_preferences() only once if more than one preference needs changing git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27089 a1c6a512-1295-4272-9138-f99709370657
* text_viewer: cleanup & bugfixRafaël Carré2010-06-20
| | | | | | | | | | | | | | | | | | | | | cleanup: - don't use enum in struct / return values - don't use a getter for preferences but a global pointer - explicitely make enums start at 0 - use static tables for header/footer settings - remove unneeded memset before strlcpy - use static buffer allocation, not dynamic - check header/footer preferences before using the callbacks - don't include font filename in archos player preferences (break file format) bugfix: - statically allocate old preferences in tv_set_preferences() Sometimes I can read a file on Clipv2, but it still aborts quite often refs: FS#11399 git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26998 a1c6a512-1295-4272-9138-f99709370657
* text viewer: can select the indent spaces when the line mode is reflow.Yoshihisa Uchida2010-06-11
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26763 a1c6a512-1295-4272-9138-f99709370657
* text viewer: can be selected the number of screens per page.Yoshihisa Uchida2010-06-06
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26613 a1c6a512-1295-4272-9138-f99709370657
* reworks text viewer plugin. (FS#11209)Yoshihisa Uchida2010-06-05
new text viewer plugin: text_viewer.rock. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26571 a1c6a512-1295-4272-9138-f99709370657