1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
Index: rockbox/apps/logfdisp.c
===================================================================
--- rockbox/apps/logfdisp.c	(révision 22249)
+++ rockbox/apps/logfdisp.c	(copie de travail)
@@ -27,6 +27,7 @@
 #include <string.h>
 #include <kernel.h>
 #include <action.h>
+#include <font.h>
 
 #include <lcd.h>
 #include "menu.h"
@@ -46,6 +47,10 @@
 
     bool lcd = false; /* fixed atm */
     int index, user_index=0;
+    int old_font;
+    
+    old_font=lcd_getfont();
+    lcd_setfont(FONT_SYSFIXED);
 
     lcd_getstringsize("A", &w, &h);
     lines = (lcd?
@@ -85,7 +90,7 @@
         
             memcpy(buffer, logfbuffer[index], columns);
             if (logfbuffer[index][MAX_LOGF_ENTRY] == LOGF_TERMINATE_CONTINUE_LINE)
-                buffer[columns-1] = '>';
+                buffer[columns-1] = /*'>'*/buffer[columns-1];
             else if (logfbuffer[index][MAX_LOGF_ENTRY] == LOGF_TERMINATE_MULTI_LINE)
                 buffer[columns-1] = '\0';
             buffer[columns] = '\0';
@@ -122,6 +127,8 @@
 #endif
     } while(action != ACTION_STD_CANCEL);
 
+    lcd_setfont(old_font);
+
     return false;
 }
 #else /* HAVE_LCD_BITMAP */
Index: rockbox/firmware/logf.c
===================================================================
--- rockbox/firmware/logf.c	(révision 22249)
+++ rockbox/firmware/logf.c	(copie de travail)
@@ -145,16 +145,17 @@
     while(len > MAX_LOGF_ENTRY)
     {
         ptr = logfbuffer[logfindex];
-        strlcpy(ptr, buf + tlen, MAX_LOGF_ENTRY);
+        memcpy(ptr, buf + tlen, MAX_LOGF_ENTRY);
         ptr[MAX_LOGF_ENTRY] = LOGF_TERMINATE_CONTINUE_LINE;
         logfindex++;
         check_logfindex();
-        len -= MAX_LOGF_ENTRY-1;
-        tlen += MAX_LOGF_ENTRY-1;
+        len -= MAX_LOGF_ENTRY;
+        tlen += MAX_LOGF_ENTRY;
         multiline = true;
     }
+    
     ptr = logfbuffer[logfindex];
-    strcpy(ptr, buf + tlen);
+    memcpy(ptr, buf + tlen,len-tlen);
 
     if(len < MAX_LOGF_ENTRY)
         /* pad with spaces up to the MAX_LOGF_ENTRY byte border */