minscay / mupen64plus

Automatically exported from code.google.com/p/mupen64plus
0 stars 0 forks source link

Missing headers, missing return value and broken variable assignments #345

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Here are some changesets fixing a number of smaller issues:

* missing headers in the input-sdl plugin and the ui-console
* a missing return value in the non-void resample function in the audio-sdl
plugin (please check first)
* broken variable assignments in the video-rice plugin

Original issue reported on code.google.com by gu...@berhoerster.name on 3 Mar 2010 at 8:43

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks! Interesting.

Strange it doesn't make crash during compile.

What platform are you? How did you find this?

Patchs doesn't seem to have probs but richard will see it and choose what to do 
(I'm
not a dev ;) )

Original comment by dorian.f...@gmail.com on 4 Mar 2010 at 2:54

GoogleCodeExporter commented 8 years ago
I'm building with GCC on Linux, with -Wall these issues all just cause 
warnings. You
might want to grep build logs or compile with -Werror and friends as part of 
your QA
before doing a release.
Particularly the audio-sdl pluin patch needs review since I'm not fully sure 
what was
intended there.

Original comment by gu...@berhoerster.name on 4 Mar 2010 at 5:31

GoogleCodeExporter commented 8 years ago
Just build the projects with

CFLAGS="-Wall -Wextra" /usr/bin/make -C projects/unix/ all CC=cgcc

and you will see that everything wants a lot of love (you need the hg version to
allow appending of cflags - wahrhafts projects doesn't support it yet). The 
static
function stuff in the core can be interesting because it can lead to reduced 
code
size and sometimes also in performance optimization (less notable). The 'unused
parameter' stuff has to be ignored in most cases since the prototype defines 
how an
plugin function has to look like.

Original comment by sven@narfation.org on 4 Mar 2010 at 7:21

GoogleCodeExporter commented 8 years ago
Started to fix some of the warnings in the -core

Before
-rwxr-xr-x 1 sven sven 624688 Mar  4 20:23 projects/unix/libmupen64plus.so.2.0.0

After
-rwxr-xr-x 1 sven sven 616496 Mar  4 21:52 projects/unix/libmupen64plus.so.2.0.0

Compiles now cleanly with

LDFLAGS="-Wl,--no-undefined -Wl,--no-add-needed" CFLAGS="-Wall" /usr/bin/make -C
projects/unix/ all

Original comment by sven@narfation.org on 4 Mar 2010 at 8:57

Attachments: