= 2009-01-14 = * Trac Wiki 改名的終極方法: 到 db/trac.db 去改內容 {{{ # sqlite3 db/trac.db sqlite> update wiki set name='BOINC/Server' where name='BOINC_Server'; }}} * 如果有附件(Attachment)的話,比較麻煩 (1) 改 wiki (2) 改 attachment (3) 必須到 attachments/wiki/ 目錄去搬檔案 {{{ # sqlite3 db/trac.db sqlite> update wiki set name='FlyCircuit/2008-03-26' where name='FlyCircit/2008-03-26'; sqlite> update attachment set id='FlyCircuit/2008-03-26' where id='FlyCircit/2008-03-26'; sqlite> update wiki set name='FlyCircuit/2008-06-24' where name='FlyCircit/2008-06-24'; sqlite> update attachment set id='FlyCircuit/2008-06-24' where id='FlyCircit/2008-06-24'; }}} == BUGFIX: jfbterm (4) == * (續 [wiki:jazz/08-11-15 08-11-15@GMT-6 BUGFIX: jfbterm (1)]) * (續 [wiki:jazz/08-11-16 08-11-16@GMT-6 BUGFIX: jfbterm (2)]) * (續 [wiki:jazz/08-11-17 08-11-17@GMT-6 BUGFIX: jfbterm (3)]) * 在看 fbcommon.c 時,發現在這組出現錯誤的 mmap 前曾跑過另一組 mmap, 因此把參數印出來對照看看。 * gdb debug 程序 {{{ file jfbterm set args -e ls show args break fbcommon.c:500 break fbcommon.c:557 break fbcommon.c:566 run p fb_fix c p fb_fix c p fb_fix.smem_len p p->soff p p->slen p fb_fix.mmem_len p p->moff p p->mlen }}} {{{ This GDB was configured as "x86_64-linux-gnu". (gdb) file jfbterm Reading symbols from /root/jfbterm-0.4.7-dev/jfbterm...done. (gdb) set args -e ls (gdb) show args Argument list to give program being debugged when it is started is "-e ls". (gdb) break fbcommon.c:500 Breakpoint 1 at 0x40303d: file fbcommon.c, line 500. (gdb) break fbcommon.c:557 Breakpoint 2 at 0x40327e: file fbcommon.c, line 557. (gdb) break fbcommon.c:566 Breakpoint 3 at 0x403301: file fbcommon.c, line 566. (gdb) run Starting program: /root/jfbterm-0.4.7-dev/jfbterm -e ls Breakpoint 1, tfbm_open (p=0x6146e0) at fbcommon.c:501 501 if (fb_var.yres_virtual != fb_var.yres) { (gdb) p fb_fix $1 = {id = "▒▒C▒\210\177\000\000\006\000\000\000\000\000\000", smem_start = 30778096, smem_len = 3032756978, type = 32648, type_aux = 0, visual = 0, xpanstep = 65535, ypanstep = 65535, ywrapstep = 65535, line_length = 1, mmio_start = 15, mmio_len = 30816528, accel = 0, reserved = {53071, 64, 0}} (gdb) c Continuing. Breakpoint 2, tfbm_open (p=0x6146e0) at fbcommon.c:557 557 p->smem = (u_char*)mmap(NULL, p->slen, PROT_READ|PROT_WRITE, (gdb) p fb_fix $2 = {id = "VESA VGA\000\000\000\000\000\000\000", smem_start = 4026531840, smem_len = 1572864, type = 0, type_aux = 0, visual = 3, xpanstep = 0, ypanstep = 0, ywrapstep = 0, line_length = 1024, mmio_start = 0, mmio_len = 0, accel = 0, reserved = {0, 0, 0}} (gdb) c Continuing. Breakpoint 3, tfbm_open (p=0x6146e0) at fbcommon.c:566 566 if(p->mlen == 0) (gdb) p fb_fix.smem_len $3 = 1572864 (gdb) p p->soff $4 = 0 (gdb) p p->slen $5 = 1572864 (gdb) p fb_fix.mmem_len There is no member named mmem_len. (gdb) p p->moff $6 = 0 (gdb) p p->mlen $7 = 0 (gdb) }}}