A patch for lesser warnings when compiled with --with-developer-flags
Description of Patch
This patch is a follow up to the new --with-developer-flags option for configure.
The patch does not change functionality or fix any bugs but it eliminates many of the warnings and could long term help expose latent defects.
Installation of Patch
Download the patch file. If it is packed as a gz or tar.gz unpack it first. Then copy it to the motion source directory and issue the command (assuming the patch file is called warnings2.diff.gz)
gunzip -cd warnings2.diff | patch
Then re-build Motion and test the patch.
Change History of Patch
- warnings - Initial revision
- warnings2 - No SEGV Version
Great work Peter.
is currently enhancing this patch as agreed on IRC so more versions are expected. I will wait integrating the patch until then.
- 14 Aug 2005
I changed a few things, particularly relating to the treatment of "char *" versus "const char *". I also put in a macro to avoid the "unused parameter" warning. The attached file (warnings3.diff.gz) should be applied against an unpatched copy of motion-3.2.2. (Not yet finished, but getting closer
- 15 Aug 2005
I have not checked this latest patch yet but for your info - I changed the code quite a few places to fix some severe bugs.
So you may want to check and fix the patch relative to the daily snap 20050816.
- 16 Aug 2005
look at used myfopen: myfopen(cnt, file, (char *)"w");
you dont need (char *)"w" anymore because of
FILE * myfopen(struct context *cnt, const char *path, const char *mode)
- 16 Aug 2005
Integrated into motion-20050818
With some modifications.
I finished the job and the 20050819 is now without warnings from the Motion sources.
I also did removed the (char *)"w".
Additional warning removal code and suggestions were done by Angel Carpintero.
Last batch of warnings were fixed by Kenneth Lavrsen.
- 18 Aug 2005