Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 197026 Details for
Bug 270899
games-arcade/cdogs-sdl-0.4 crash on amd64
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
cdogs-sdl-0.4-64bit.patch
cdogs-sdl-0.4-64bit.patch (text/plain), 1.02 KB, created by
Tristan Heaven (RETIRED)
on 2009-07-07 09:40:03 UTC
(
hide
)
Description:
cdogs-sdl-0.4-64bit.patch
Filename:
MIME Type:
Creator:
Tristan Heaven (RETIRED)
Created:
2009-07-07 09:40:03 UTC
Size:
1.02 KB
patch
obsolete
>--- src/grafx.c >+++ src/grafx.c >@@ -216,12 +216,6 @@ > SDL_VideoQuit(); > } > >-typedef struct _Pic { >- short int w; >- short int h; >- char *data; >-} Pic; >- > int ReadPics(const char *filename, void **pics, int maxPics, > color * palette) > { >@@ -241,12 +235,12 @@ > fread(&size, sizeof(size), 1, f); > swap16(&size); > if (size) { >- Pic *p = sys_mem_alloc(size); >+ unsigned char *p = sys_mem_alloc(size); > >- f_read16(f, &p->w, 2); >- f_read16(f, &p->h, 2); >+ f_read16(f, &p[0], 2); // w >+ f_read16(f, &p[2], 2); // h > >- f_read(f, &p->data, size - 4); >+ f_read(f, &p[4], size - 4); // data > > pics[i] = p; > >@@ -278,11 +272,11 @@ > fread(&size, sizeof(size), 1, f); > swap16(&size); > if (size) { >- Pic *p = sys_mem_alloc(size); >+ unsigned char *p = sys_mem_alloc(size); > >- f_read16(f, &p->w, 2); >- f_read16(f, &p->h, 2); >- f_read(f, &p->data, size - 4); >+ f_read16(f, &p[0], 2); // w >+ f_read16(f, &p[2], 2); // h >+ f_read(f, &p[4], size - 4); // data > > pics[i] = p; >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 270899
:
192159
| 197026