?? xdmesg.c
字號:
#include <xenctrl.h>#include <xenguest.h>#include <stdio.h>#include <errno.h>#include <stdlib.h>#include <string.h>#include <ctype.h>#include <xs.h>#include <fcntl.h>#include <sys/mman.h>#define RING_SIZE 4096*8int xc;int main(int argc, char** argv){ char* b= (char*) mmap(0,RING_SIZE, PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, 0,0); char* a = b; unsigned int n=RING_SIZE; int i; xc = xc_interface_open(); xc_readconsolering(xc,&b,&n,1); for(i=0; i<n; i++) if(!isascii(a[i])) a[i]=' '; a[n]='\0'; xc_interface_close(xc); puts(a); return 0;}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -