Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:digitaltomm
vbetool
vbetool-1.1-misc-warnings.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File vbetool-1.1-misc-warnings.patch of Package vbetool
Index: b/vbetool.h =================================================================== --- a/vbetool.h +++ b/vbetool.h @@ -15,5 +15,5 @@ void text_mode(void); int check_console(void); int enable_vga(void); int disable_vga(void); -int do_get_panel_id(); +int do_get_panel_id(int); Index: b/vbetool.c =================================================================== --- a/vbetool.c +++ b/vbetool.c @@ -254,8 +254,8 @@ void restore_state_from(char *data) r.eax = 0x4f04; r.ecx = 0xf; /* all states */ r.edx = 2; /* restore state */ - r.es = (unsigned int) (data - LRMI_base_addr()) >> 4; - r.ebx = (unsigned int) (data - LRMI_base_addr()) & 0xf; + r.es = (unsigned short int) (((long)(data - LRMI_base_addr())) >> 4); + r.ebx = (unsigned int) (((long)(data - LRMI_base_addr())) & 0xf); r.ds = 0x0040; if (!LRMI_int(0x10, &r)) { @@ -329,15 +329,15 @@ char *__save_state(int *psize) memset(&r, 0, sizeof(r)); - fprintf(stderr, "Allocated buffer at %p (base is 0x%x)\n", buffer, + fprintf(stderr, "Allocated buffer at %p (base is 0x%zx)\n", buffer, LRMI_base_addr()); r.eax = 0x4f04; r.ecx = 0xf; /* all states */ r.edx = 1; /* save state */ - r.es = (unsigned int) (buffer - LRMI_base_addr()) >> 4; - r.ebx = (unsigned int) (buffer - LRMI_base_addr()) & 0xf; + r.es = (unsigned short int) (((long)(buffer - LRMI_base_addr())) >> 4); + r.ebx = (unsigned int) (((long)(buffer - LRMI_base_addr())) & 0xf); r.ds = 0x0040; fprintf(stderr, "ES: 0x%04X EBX: 0x%04X\n", r.es, r.ebx); @@ -525,11 +525,11 @@ int do_get_panel_id(int just_dimensions) .ebx = 0x0001 }; struct panel_id *id = LRMI_alloc_real(sizeof(struct panel_id)); - r.es = (unsigned short)(((int)(id-LRMI_base_addr()) >> 4) & 0xffff); + r.es = (unsigned short)(((long)(id-LRMI_base_addr()) >> 4) & 0xffff); r.edi = (unsigned long)(id-LRMI_base_addr()) & 0xf; if(sizeof(struct panel_id) != 32) - return fprintf(stderr, "oops: panel_id, sizeof struct panel_id != 32, it's %ld...\n", sizeof(struct panel_id)), 7; + return fprintf(stderr, "oops: panel_id, sizeof struct panel_id != 32, it's %zd...\n", sizeof(struct panel_id)), 7; if(real_mode_int(0x10, &r)) return fprintf(stderr, "Can't get panel id (vm86 failure)\n"), 8;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor