1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-01-14 15:36:34 +00:00

706 Commits

Author SHA1 Message Date
Nick Briggs
ce97f136ec Declare unexported variables static and remove unused debug-related variables. 2023-02-17 17:01:27 -08:00
Nick Briggs
bb1b541014 Add extern declarations for globals defined in xlspwin.c 2023-02-17 17:01:27 -08:00
Nick Briggs
7e2620db20 Remove extraneous forward declaration of contextsw() 2023-02-17 17:01:27 -08:00
Nick Briggs
679b201849 Remove unused #defines 2023-02-17 17:01:27 -08:00
Nick Briggs
7eb3cd0ceb Address alignment warnings for createcell68k()
createcell68k(typecode) returns a pointer that is aligned for the typecode
argument.  Changing the return type to "void *" puts the onus on the caller
to cast the result to an appropriately aligned object.  All current uses
in the maiko source ask for 4-byte objects (TYPE_FIXP, TYPE_FLOATP).
2023-02-17 17:01:27 -08:00
Nick Briggs
9bfeaeb8b4 Resolve warning because URaid_comm string as a target of a sscanf() must have space for a terminating NUL 2023-02-17 17:01:27 -08:00
Nick Briggs
7eb87576f5 cursorlist and cursor fore/background colors are local to module and can be static. 2023-02-17 17:01:27 -08:00
Nick Briggs
4b3997b432 The todo_... variables are not referenced elsewhere and can be static. 2023-02-17 17:01:27 -08:00
Nick Briggs
a536faa736 Reduce missing-variable-declarations, move some atom index extern definitions to lspglob.h. 2023-02-17 17:01:27 -08:00
Nick Briggs
4834f6f2b1 Eliminate various warnings from vmemsave.c/vmemsavedefs.h
* sort_fptovp() and twowords() can be static and are sometimes (depending on flags)
   not needed at all
 * roundup() macro is unused and can be removed
 * maxpages can be unsigned (affects main.c)
 * variables used for return values of system calls should be correctly declared
 * pointers into Lisp_world should be DLword* rather than char*, and
   computations must take that into account.
 * ENOSPC and EDQUOT errors on write should return NOFILESPACE instead of FILECANNOTWRITE error.
2023-02-17 17:01:27 -08:00
Nick Briggs
766de557bb Cleanup warnings from byte swapping routines 2023-02-17 17:01:27 -08:00
Nick Briggs
6b41fcea17 Use PVar macro rather than directly referencing MState->pvar; MState itself is another macro. 2023-02-17 17:01:27 -08:00
Nick Briggs
a17460cd6b Remove unused atom_to_str() function and the warning it generates 2023-02-17 17:01:27 -08:00
Nick Briggs
960baf9b96 fix signedness issue in N_OP_bind(unused), matching correction made in inlineC.h BIND in 26e67a51 2023-02-17 17:01:27 -08:00
Nick Briggs
5c81ca3f41 Resolve warning: 'DOS' (and 'SUNDISPLAY') is not defined, evaluates to 0; use #ifdef/#if defined(...) 2023-02-17 17:01:27 -08:00
Nick Briggs
38761fbd93 Resolve warning: unreachable-code-break (remove break following return) 2023-02-17 17:01:27 -08:00
Nick Briggs
7b67b3f79f Use in_display_segment(...) macro where possible. 2023-02-17 17:01:27 -08:00
Nick Briggs
a6b8b65b5b Remove extern references for variables already present in lspglob.h, and subsequent extraneous includes for their types 2023-02-17 17:01:27 -08:00
Nick Briggs
11efd15613 Clean up usage of the native address of the MiscStats and its struct typedef
The global variable MiscStats is declared extern in "lspglob.h"
The structure that MiscStats points to is MISCSTATS and is defined in "miscstats.h"
2023-02-17 17:01:27 -08:00
Nick Briggs
b71a8088d3 Uncomment and correct spelling error in use of getrusage() result, ru_outblock => ru_oublock 2023-02-17 17:01:27 -08:00
Nick Briggs
1c6277d313 Clean up usage of the native address of the I/O page and its struct typedef
The global variable holding the native address of the I/O page is spelled "IOPage"
The global variable "IOPage" is declared extern by "lspglob.h"
The structure pointed to by IOPage is named IOPAGE and is defined in "iopage.h"
If there is no direct reference to the IOPAGE struct do not include "iopage.h"
2023-02-17 17:01:27 -08:00
Nick Briggs
43809d070b Fix a few sign-conversion and shorten-64-to-32 warnings while converting some values from int to unsigned 2023-02-17 17:01:27 -08:00
Nick Briggs
60a9497e7a Remove extraneous extern declarations duplicated from lspglob.h 2023-02-17 17:01:27 -08:00
Nick Briggs
2e6aba0d19 Fix warning for dropping const in cast 2023-02-17 17:01:27 -08:00
Nick Briggs
e1c4263dd8 Remove extraneous extern references for Lisp_world that are covered by lspglob.h 2023-02-17 17:01:27 -08:00
Nick Briggs
67d9ee8b07 Fix four each implicit-int-conversion and cast-qual warnings in mkatom.c 2023-02-17 17:01:27 -08:00
Nick Briggs
2b7228f37e Remove typedefs for function pointers and their uses. Methods which are defined but never used get (void) args until they are implemented. 2023-02-17 17:01:27 -08:00
Nick Briggs
4853f0e3f5 Fix missing prototype adding ttydefs.h, declare tty_baudtosymbol() as static. 2023-02-17 17:01:27 -08:00
Nick Briggs
a1e5e6eecc fix warning: break will never be executed 2023-02-17 17:01:27 -08:00
Nick Briggs
748c52fbaa lispcmp should be declared static 2023-02-17 17:01:27 -08:00
Nick Briggs
6d7b4c1cd2 panicuraid should be declared static 2023-02-17 17:01:27 -08:00
Nick Briggs
80c9c796c5 Address "warning: passing arguments to a function without a prototype is deprecated in all versions of C and is not supported in C2x"
* Update struct DevRec methods to take a "void *" parameter
   since they get called with different xxxInterface records
   depending on whether they are a keyboard, mouse, or display.
   Introduce GenericReturnVoid method implementation for use
   where needed with DevRec methods. (see mouseif.c)

 * Cast functions implementing DevRec methods as appropriate to match
   the method signature.

 * Update struct DspInterfaceRec methods cleardisplay,
   bitblt_to_screen, mouse_invisible, and mouse_visible to declare
   the parameters they require and all return unsigned long results
   (though it's not clear that this is actually the correct type).
   Requires updating dosmouse.c method implementations.

 * Update GenericReturnT and GenericPanic method implementations
   to have the signature required by the method slots they
   are used in.

 * Correct DOS-only section with incorrect arguments to device.exit
   call for the mouse.

 * Use include "dspifdefs.h" for prototypes for GenericReturnXXX method
   implementations.
2023-02-17 17:01:27 -08:00
Nick Briggs
80e40fa942 Fix warning: The left operand of \'==\' is a garbage value 2023-02-17 17:01:27 -08:00
Nick Briggs
38bf60c626 Static analysis suggests (incorrectly) that a reference *srcbase accesses uninitialized memory in grayword.
Correct its misunderstanding by explicitly initializing all elements of grayword[4] to 0.
2023-02-17 17:01:27 -08:00
Nick Briggs
0ba8380aea Don't reference uninitialized fields in DspInterface when processing window events in no-scroll case.
Initialize variables to suppress "may be uninitialized when used here" warning that couldn't actually happen.
2023-02-17 17:01:27 -08:00
Nick Briggs
8054c62f8a Ensure XImage and XEvent variables are completely initialized 2023-02-17 17:01:27 -08:00
Nick Briggs
ab79048dae fix warning: incompatible function pointer types for file sort functions in dir.c 2023-02-17 17:01:27 -08:00
Nick Briggs
e03782c6b6 fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
14c5f9245e fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
c6b7eb7fd7 Fix incorrect prototype 2023-02-17 17:01:27 -08:00
Nick Briggs
3ccc28d16a fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
51cae2af8d fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
f0f33fe587 fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
9ab1215fc8 fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
a3ba41fba2 fix warning: a function declaration without a prototype is deprecated in all versions of C
make savestr() static and remove it from dlpidefs.h since it is not used outside of dlpi.c
2023-02-17 17:01:27 -08:00
Nick Briggs
39a716ace8 fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
bae09d8eba fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
6838c701cc fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
2175364380 fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00
Nick Briggs
202db168a9 fix warning: a function declaration without a prototype is deprecated in all versions of C 2023-02-17 17:01:27 -08:00