1. 13 Nov, 2021 1 commit
  2. 06 Feb, 2021 1 commit
  3. 05 Sep, 2020 1 commit
    • Ben Avison's avatar
      Enable modulewrapped applications to use ResGen · 073ebc25
      Ben Avison authored
      This utilises a weak symbol import so that if the symbol `Resources` resolves
      at link time, it is called to discover the address of the resource file data
      block(s) to be installed in ResourceFS. If this fails, it drops back to using
      the `s.ResFiles` source file as previously, thereby ensuring compatibility
      with components that have not yet been converted to use ResGen.
      Since `Resources` is the default area name (and thus discovery function name)
      used for ResGen in the shared makefiles, this makes it as simple as possible
      to utilise it.
      Version 6.08. Tagged as 'RISC_OSLib-6_08'
  4. 06 Jul, 2020 1 commit
    • Jeffrey Lee's avatar
      Adjust 26 vs. 32 bit mode checks · fa89c230
      Jeffrey Lee authored
      As noted in https://www.riscosopen.org/forum/forums/9/topics/15359, MRS
      instructions which are executed in user mode may return unknown values
      for the CPSR E, A, I, F and M fields on ARMv8 CPUs. At the moment the
      only observed deviation from normal behaviour is that CPUs which lack
      AArch32 privileged-mode support may return zero for the fields. This was
      found to confuse some 26 vs. 32 bit mode checks in CLib.
      Clearly we're a long way away from having a version of RISC OS which can
      run on a CPU that lacks AArch32 privileged mode support, but we can
      still try and make sure user-mode applications are compatible with them.
      So this change adjusts the mode checks in the stubs and overlay manager
      so that programs linked with them should function correctly (TEQ is now
      used instead of MRS)
      Note that once we do start porting RISC OS to one of the troublesome
      CPUs, there are many more potentially troublesome MRS's within the
      module code that will need adjusting, especially if CPUs start returning
      values other than zero.
      Version 6.07. Tagged as 'RISC_OSLib-6_07'
  5. 09 May, 2020 2 commits
    • Jeffrey Lee's avatar
      txtar: Support extended scroll requests · d3688b4c
      Jeffrey Lee authored
      Use extended scroll requests to handle mouse wheel scrolling, to avoid
      the "thumbing" code getting confused and thinking the user is dragging
      the scrollbar (the "thumbing" mode of scrolling isn't desirable for the
      mouse wheel, because it largely ignores the requested scroll distance)
      This change allows Edit & SrcEdit (and anything else using txtar) to
      handle the scroll wheel better, now that the WindowScroll module is
      controlling things.
      Version 6.06. Tagged as 'RISC_OSLib-6_06'
    • ROOL's avatar
      Extra rlib sprite function for ROM stubs · f41e4118
      ROOL authored
        Export sprite_put_mask_scaled when UROM.
        Also, delete sprite_put_greyscaled() which has been unimplemented in SpriteExtend since RISC OS 3.60.
        Required by Paint bounty.
      Version 6.05. Not tagged
  6. 06 May, 2020 1 commit
  7. 22 Apr, 2020 1 commit
  8. 20 Jul, 2019 1 commit
  9. 29 Jun, 2019 1 commit
  10. 09 Jun, 2019 1 commit
    • ROOL's avatar
      Build fix · 20984a33
      ROOL authored
        Add missing function draw_create_diag() to the ROM version of RISC_OSLib, required by Paint-2_24 and later.
        To keep ROM footprint to a minimum, export only that function; this also avoids adding static workspace and needing to increase RlibSpace.
      Version 6.01. Tagged as 'RISC_OSLib-6_01'
  11. 17 Mar, 2019 1 commit
    • ROOL's avatar
      Build fix · 6982f5cc
      ROOL authored
        Add wimp_autoscroll to rlib entries.
      Version 6.00. Not tagged
  12. 16 Mar, 2019 1 commit
    • ROOL's avatar
      CLib and rlib header updates · 0c846685
      ROOL authored
        Export fenv.h (omitted in error).
        Add FP_FAST_FMAL and FP_FAST_FMA defines per C standard
        Submission for ARMv7 Compiler bounty.
        Add Wimp_AutoScroll supporting function to rlib.
        Export various related defines for autoscroll use.
        Submission for Clipboard Support bounty.
      Version 6.00. Tagged as 'RISC_OSLib-6_00'
  13. 09 Feb, 2019 1 commit
    • ROOL's avatar
      Fix to iconbar menu X offset · 2f520d7e
      ROOL authored
        The fix applied to all menus in event.c revision 4.6 didn't take into account the offset of -16 already applied to iconbar menus.
        Tested with Draw-1_31.
      Version 5.99. Tagged as 'RISC_OSLib-5_99'
  14. 26 Jan, 2019 1 commit
    • Robert Sprowson's avatar
      Various fixes · a8f233bb
      Robert Sprowson authored
      colourtran.c: Swap round arg names to colourtran_colournumbertoGCOL to match prototype.
      txtar.c: Avoid incorrect use of strncat buffer limit, and possible unterminated string after strncpy, by reexpressing using snprintf.
      txtedit.c: Avoid incorrect use of strncat buffer limit by reexpressing using snprintf. Avoid potential NULL pointer dereference by moving the filename copy inside the 'if' which confirms it's non-NULL.
      txtfind.c: Remove repeated check of repls being valid. Free repls on error. Free pat on error.
      xfersend.c: Fix potential out of bounds array access (of leaf[]) if the leafname length exceeds the space in the Wimp message.
      Found by cppcheck static analysis.
      txtopt.c/h: Sprinkle in some consts.
      event.c: Open menu at the Style Guide approved offset of 64.
      xfersend.c: Remove redundant check of xfersend__filename being NULL in xfersend__suggest_leaf() as all paths leading to it being called ensure the allocation exists (also, it would have strcpy'd garbage due to malloc not clearing the allocation).
      Removed unused header txtover.h.
      Version 5.98. Tagged as 'RISC_OSLib-5_98'
  15. 11 Jun, 2018 1 commit
    • Jeffrey Lee's avatar
      Fix to CopyError change · 0a8fe9be
      Jeffrey Lee authored
        kernel/s/k_body - CPSR_f is the correct field for the NZCV flags, not _c
      Version 5.97. Tagged as 'RISC_OSLib-5_97'
  16. 10 Jun, 2018 1 commit
    • Jeffrey Lee's avatar
      Try and avoid blocking callbacks · 73fd8884
      Jeffrey Lee authored
        The kernel has a 'callback postponement flag' which will be set whenever an X SWI, called from user mode, returns a pointer to an error (and the error block looks like it's in RAM).
        Although this flag will help prevent the error buffer from being overwritten by any errors generated by callbacks, it will also have the effect of blocking Alt-Break and CLib's Escape handler, due to them both being reliant on callbacks.
        Since the flag may persist for a long time, it can be dangerous to leave the OS in this state (the flag can only be cleared by a SWI call from user mode - which may never happen if the program is stuck in a bad state).
        So to combat this, CLib will now make some effort to try and avoid leaving the postponement flag in situations where it shouldn't be needed.
        File changes:
        - c/armsys:
          - Change _sys_flen to return 0 for TTY streams, since calling OS_Args for them isn't going to generate any useful result (previously it was generating an error, causing the postponement flag to be left set on entry to main())
          - Be extra vigilant when entering main() to make sure the callback postponement flag isn't set, just in case other checks don't resolve it
        - kernel/s/k_body:
          - Change CopyError to attempt to clear the callback postponement flag if we suspect it's set. We've just copied the error to our own buffer, so it should be our job to worry about preventing that buffer being prematurely overwritten, not the kernel's.
        Tested on BB-xM
        'while (1) {}' (and similar variants) now multitasks in task windows and is no longer unkillable
        Fixes issue reported on forums:
      Version 5.96. Tagged as 'RISC_OSLib-5_96'
  17. 14 Apr, 2018 1 commit
    • Jeffrey Lee's avatar
      Make abort handling more robust · e4577090
      Jeffrey Lee authored
        kernel/s/k_body - Update AbortFindHandler to check that SP & SL are both word aligned, especially because the code will attempt to load from SL to check for the stack chunk magic marker.
        Tested on BB-xM
        Avoids some "abort while in abort handler" type scenarios if an abort occurs while SP/SL are invalid
      Version 5.95. Tagged as 'RISC_OSLib-5_95'
  18. 29 Oct, 2017 1 commit
    • Robert Sprowson's avatar
      Put ctl in the attic · 91926745
      Robert Sprowson authored
      The ctl part of rlib has various memory leaks (ref https://www.riscosopen.org/forum/forums/4/topics/9503) reflecting its abandoned state. See the FrontEnd module for a more flexible implementation of the same GUI-in-a-text-file scripting language.
      The ctl API was not in C release 3 (it post dates that) nor in C release 4 manual, and the whole of rlib was removed from C release 5 in favour of the Toolbox.
      The change log at the top of rlib/s/rl_spare shows it was briefly added in early 1990 then removed in April 1991. 26 years later, cull it from the Makefile too.
      Version 5.94. Tagged as 'RISC_OSLib-5_94'
  19. 03 Sep, 2017 1 commit
    • Jeffrey Lee's avatar
      Eliminate some global OS_SynchroniseCodeAreas calls · d89ca652
      Jeffrey Lee authored
        kernel/s/k_body - Eliminate a couple of global OS_SynchroniseCodeAreas calls in _kernel_init and _kernel_system
        s/initmodule - Eliminate a global OS_SynchroniseCodeAreas call in _Shared_Lib_Module_SWI_Code
        Tested on iMx6
        Improves performance with SMP ROMs, where global D-cache clean isn't really possible
      Version 5.93. Tagged as 'RISC_OSLib-5_93'
  20. 28 May, 2016 1 commit
    • Jeffrey Lee's avatar
      Remove ARM2 NOPs · e52669b7
      Jeffrey Lee authored
        kernel/s/k_body, s/initmodule - Remove NOPs from after PSR manipulation macros; the macros now fully take care of ARM2 & StrongARM compatibility for us
        Tested PlingSystem build on (ARM3) RISC OS 3.1
        Requires HdrSrc-2_63 for ARM2 compatibility
      Version 5.92. Tagged as 'RISC_OSLib-5_92'
  21. 24 May, 2016 1 commit
    • Jeffrey Lee's avatar
      When multiple CPU architectures are supported, allow dynamically linked... · f3f167bc
      Jeffrey Lee authored
      When multiple CPU architectures are supported, allow dynamically linked clients to be given optimal versions of routines where possible
        This set of changes adds support for representing architecture-specific variants of routines within the export tables which the shared C library uses to fill in the client's stubs.
        This allows builds of the module which target multiple architectures (e.g. IOMD, Raspberry Pi, or softloads) to offer the most optimal versions of routines to clients wherever multiple variants exist.
        If only one architecture is supported, only one version of each routine will be built, and no variant tables will be generated.
        Currently routine selection for staticly linked clients isn't supported - staticly linked targets will only use the most backwards-compatible version of the routines, as before. Also not all routines are catered for yet (e.g. _ll_udiv)
        File changes:
        - s/h_common - New file containing macros used during variant table construction
        - Makefile - Set SHARED_C_LIBRARY to {TRUE} for SCL builds of assembler code, as per the SHARED_C_LIBRARY #define
        - kernel/s/k_body, s/longlong - For routines which have multiple variants available for the target architectures, build all variants, and generate variant table entries using the new RoutineVariant macro. This has required some reordering of the different variants to make sure that when both versions are built, the most backwards-compatible one will be first (and thus will be called by staticly linked clients)
        - s/h_modmacro - "Entry" macro (when building SCL export tables) changed to use DCD instead of B, to allow byte-aligned symbols to be represented (low bits of symbol address is now used as 'is a variant table' flag)
        - s/initmodule - Client stub initialisation rewritten to take into account the B -> DCD change, and to detect and evaluate variant entries
        - clib/s/cl_entries, kernel/s/k_entries, kernel/s/k_entries2 - Update library entry tables to reference the variant forms of routines where relevant
        Tested on Raspberry Pi 1, 2, 3 (ROM), RISC OS 3.1 & StrongARM 3.7 (softload 26bit build)
        Requires Kernel-5_35-4_79_2_325
      Version 5.91. Tagged as 'RISC_OSLib-5_91'
  22. 14 May, 2016 1 commit
    • ROOL's avatar
      [391] localtime() ignores manual timezone configuration · 332c9e74
      ROOL authored
        When in the default C locale localtime() would return the wrong time for nonzero timezones.
        Tested with softloaded C library for each ROM release supported.
        Submission from Rick Murray.
      Version 5.90. Tagged as 'RISC_OSLib-5_90'
  23. 08 May, 2016 1 commit
    • Jeffrey Lee's avatar
      Prefer CPS over MSR for PSR manipulation. Use UDIV/SDIV for general-purpose... · 377852c3
      Jeffrey Lee authored
      Prefer CPS over MSR for PSR manipulation. Use UDIV/SDIV for general-purpose division, and UMULL for /10.
        - _kernel_irqs_off and _kernel_irqs_on now use CPS for disabling/enabling IRQs as opposed to MSR. Apart from being shorter code sequences, it's generally a faster instruction.
        - __rt_udiv and __rt_sdiv (and aliases) now use the UDIV and SDIV instructions if building for ARMv7VE
        - __rt_udiv10 and __rt_sdiv10 (and aliases) now use UMULL to multiply by 1/10 when building for targets with long multiply support, as this is faster than the old method. UDIV/SDIV can be fast too, but only for small numbers, making UMULL the best for the general case.
        Tested on Cortex-A15
        Prototyping of division routines on assorted CPUs shows that UDIV/SDIV is generally between 20% and 400% faster than the old routine (Cortex-A7, Cortex-A53), or up to 1300% faster on Cortex-A15 (the CPU does not like the old routine!)
        Division by 10 is now about 20% faster across all appropriate CPUs
      Version 5.89. Tagged as 'RISC_OSLib-5_89'
  24. 29 Feb, 2016 1 commit
    • Ben Avison's avatar
      Support for ARMv8 · 9b78d05f
      Ben Avison authored
        The SWP and SWPB instructions have finally been removed in ARMv8, after
        having been deprecated for a very long time. This version adds alternative
        versions of code that used to use them with ones that use LDREX/STREX and
        LDREXB/STREXB instead. Soft-loadable C libraries will choose between
        implementations at runtime using OS_PlatformFeatures; ROM builds only
        include the appropriate version for the target hardware.
        Tested on Raspberry Pi 3.
      Version 5.88. Tagged as 'RISC_OSLib-5_88'
  25. 13 Feb, 2016 1 commit
    • ROOL's avatar
      Remove arbitrary limits on menu sizes · 758802b2
      ROOL authored
        When RISC_OSLib is used to generate menus using menu_new and menu_extend
        there are two (undocumented?) limits on the total menu size:
        - 64 items on a menu. Any more are silently ignored.
        - 1024 bytes of indirect text. Above this, any items have
          several bytes of random rubbish displayed in the menu entry.
        rlib.c.menu (r4.6) has been changed to:
        - remove menu_workarea which was on the stack, and caused limits.
        - only use malloc'd storage areas for the menu.
        - reduce the data copied by at least 50% by changing processing
          from: copy; update; copy
          to  : realloc extend (& copy?); update; realloc shrink (no copy).
        - remove the limits by adding more storage dynamically.
        - simplify code, which reduces the object code size by about 7%.
        The changes have been tested on an Iyonix running RO5.23, and VRPC
        running RO4.39, with a large C program with about 80 menus.
        The only noticeable effects were beneficial.
        It has also been tested with artificially low ADDITEMS and ADDBYTES.
        Submission from Martin Avison.
      Version 5.87. Tagged as 'RISC_OSLib-5_87'
  26. 07 Feb, 2016 1 commit
    • Robert Sprowson's avatar
      Open colour picker menus in the right place · ec3972c5
      Robert Sprowson authored
      Function dboxtcol() always opens colour pickers as transient submenus (in the flags to ColourPicker_OpenDialogue, plus listening for the menus deleted message) but chose to open the dialogue at the current mouse pointer, so obscuring part of the menu rather than opening it where the Style Guide wants it.
        Add a struct definition of menuwarn messages.
        Use the menuwarn struct rather than indexing the words[].
        Provided the last wimp event was the menu warning, use the x/y coordinates from that instead of the mouse pointer.
        Remove some local defines in favour of central ones.
        Make sure we use 0x80000000/0x7F000000 like the PRM says for the other 2 corners of the dialogue, not 0,0.
      Tested in a disc build of !Draw.
      Version 5.86. Not tagged
  27. 30 Jun, 2015 1 commit
    • Jeffrey Lee's avatar
      Fix null pointer dereference in stack backtrace code · 1aa3b81b
      Jeffrey Lee authored
        c/armsys - _kernel_language will return NULL if the PC was outside any known library language block, so make sure to check for that before dereferencing the pointer
        Builds, untested
      Version 5.86. Tagged as 'RISC_OSLib-5_86'
  28. 03 Apr, 2015 2 commits
    • Robert Sprowson's avatar
      Switch from ArcEdit style model to clipboard cut & paste model · 99904b10
      Robert Sprowson authored
      The txt library part of RISC_OSLib was essentially contrary to everything Acorn was telling its developers, to use the global clipboard.
      Additionally, support is added for swap case within a selection.
       Add a new charoption type 'txt_READONLY' to inform txt that the buffer is notionally read only, this is used to supress 'Paste' in the selection menu when appropriate.
       Correct some typos in the comments.
       Kill off modula 2 dummy structure member.
       Remove unused function export.
       Rename basicimport to be consistent with the text version of the same function. We use 'import' to denote RAM transfers and 'insert' to denote file/scrap transfers throughout.
       Redundant internal functions removed.
       Add a new undo operation type 't' for swap case, to avoid polluting the undo buffer with an entire copy of the text where only the case changed.
       Kill off modula 2 double pointer requirement.
       Unused structure member 'selectctl' removed.
       Kill off modula 2 double pointer requirement.
       Refactor message despatch with a switch statement so the save/load/open operations are explicitly checked for, in case the application enables other messages.
       Adopt MOVERWRITE, been enabled since 1988 so is probably good to keep.
       Dynamically generate the Select menu by first sending a clipboard request, and fading Paste if no reply comes back.
       Implement changed mouse selection logic.
       Implement different hotkeys and caret navigation.
       Implement copy and paste/replace operations.
       Implement swap case operation.
       Type corrections and function rename admin.
       Implement copy and paste/replace operation for detokenised BASIC.
       Supporting functions for clipboard added, supporting functions for ArcEdit removed.
       Make sure the caret is visible for programmatical zero sized selections.
       Allow suspension of undo during known complex operations, such as import via RAM transmit. This was a longstanding bug where the import buffer was grabbed in ~4k chunks (even if only 1 byte was being transferred) which in turn resulted in a +4000 undo insertion and a -3999 removal, which given the default undo buffer is only 5k would result in it failing the reversibility test, so no undo was possible.
       Now, during a RAM transmit undo is suspended until the total transfer size is known, and only that data is placed in the undo buffer (subject to the same 5k reversibility limit).
       Add new undo type 't' for swap case operation.
       4 new ints and 1 new BOOL, so RlibSpace increases by 5.
      Version 5.85. Tagged as 'RISC_OSLib-5_85'
    • Robert Sprowson's avatar
      Extend rlib xferrecv API · 97c92ee5
      Robert Sprowson authored
      Add xferrecv_last_ref to get hold of the Wimp message id of the request for a scrap file data save, when the RAM transfer gets no reply. This is useful to allow the data save to be distinguished from a file being dragged to an application, without having to resort to string compares against <wimp$scrap>.
       Also add RTC to SWI exports, and remove redundant ones.
       Treat cmd_string as a pointer.
       New function xferrecv_last_ref.
      Version 5.84. Tagged as 'RISC_OSLib-5_84'
  29. 23 Aug, 2014 1 commit
    • Robert Sprowson's avatar
      Minor rlib cleanups · dc7ea073
      Robert Sprowson authored
      dbox.c: address of cancelled by dereference
      event.c: spelling
      txtar.c: don't grab the caret when clicking toggle size
      txtedit.c: use BOOL for a boolean
      win.c: when looking at the behind window handle we want -1 not 'DUD' (which happens to be -1)
      wimp.h: add comment about window handle -3
      Retagged as RISC_OSLib-5_83.
      Version 5.83. Not tagged
  30. 31 Jul, 2014 1 commit
    • Robert Sprowson's avatar
      Some RISC_OSLib rlib enhancements · 5b7cef10
      Robert Sprowson authored
      Add a new menu_setcolours() function to allow the fore/background colour bits to be set on a menu entry.
      Use the new menu_setcolours() function instead of making assumptions about menu's internal structure layout.
      New functions dbox_hidefield and dbox_unhidefield added to complement the fade/unfade ones.
      As dbox_findicon/findiconbefore are only ever used to find writables, rename them as such. Also, make them find writable (type 15) AND writable draggable (type 14) icons.
      Allow navigation by tab/shift tab through icons like the Style Guide chapter 16 says we should. In fact it's a little odd that dbox is emulating 'Ktar' validation itself manually when the Wimp has done this since version 2.92, but maintaining it is less effort than going and checking all the templates.
      Fix bug when looking for leading capital letter matches to complete a dbox, the previous code was looking at the cached copy of the icon flags in d->window rather than the ones the Wimp is actually showing on screen (as might have been modified by dbox_fadefield() for example), so it was possible to complete a dbox for an icon which wasn't visible or selectable.
      Fix bug when looking for leading capital letter matches when the icon doesn't have any text - the template file format is defined as being 0x0D terminated. This would then lead to 'R' and 'S' being accepted as matches having run off the end of the text buffer and into the validation string (which usually contains an 'R' or 'S' validation first). Changed to accept any control terminator.
      When force closing the current menu, don't forget to set the two state variables back to 0.
      Use existing pointer type definitions.
      Treat bools as bools and pointers as pointers.
      Say something useful in an error box if flex fails its internal consistency check, rather than just data aborting.
      Remove ROM conditionals from around font_readdef() function, always include the function.
      Use font_readdef() rather than local copies of the exact same function.
      Remove redundant 'deletepending' state variable, and confusion over 'selectrecent' being a bool.
      Call os_byte directly rather than passing to os_cli("*FX").
      Other minor tidy ups.
      Mark messages list as a constant.
      Also preserve the size member while recycling the xferrecv_ack message block, rather than corrupting it as 256.
      Take out the leaf name formulator as a common function for the two places to use it. This also allows the function to return the length of the leaf name so the correct message block size can be used. Inspection with MsgMon/!Reporter was showing that all xfersend initiated saves were passing the leaf name padded to 256 with garbage.
      Reindent a few functions.
      Make the draggable sprite replacement follow the same validation string rules as the Wimp, previously only ";s" was accepted, so upper case 'S' and validation strings that start with the sprite validation didn't work.
      xfersend_pipe() function prototype changed to match xfersend() more closely - not being able to respond to the context of a wimp_eventstr made this function practically unusable.
      Windows logo and menu keys defined.
      Some typos in comments.
      Missing wimp message action codes and structure defs added for completeness.
      Version 5.83. Not tagged
  31. 08 Jul, 2014 1 commit
  32. 15 Jun, 2014 1 commit
    • Ben Avison's avatar
      Add C99 standard headers wchar.h and wctype.h · 3ed0fb98
      Ben Avison authored
        These were previously languishing in the C compiler sources, but they
        belong in the C library. Note however that the library does not implement
        the functions described in these headers at the present time, so any
        attempt to use them will result in link-time errors.
        Untested (known not working)
      Version 5.83. Tagged as 'RISC_OSLib-5_83'
  33. 08 May, 2014 1 commit
    • Robert Sprowson's avatar
      Check for NULL pointers before finding the syshandle · da9f2a03
      Robert Sprowson authored
      menu.c: if NULL return -1, this has the added advantage that a menu maker (see event_attachmenumaker) can return NULL to mean "no menu thanks" and not data abort in event.c
      dbox.c: if NULL return 0, this is somewhat consistent with template_syshandle()
      menu.h: typo in comment corrected
      Version 5.82. Tagged as 'RISC_OSLib-5_82'
  34. 25 Mar, 2014 1 commit
    • Ben Avison's avatar
      Unbreak stdio.h for C90 mode · 83945ac3
      Ben Avison authored
        Large file support made use of long longs in various definitions. These
        were switched out in PCC mode, but no allowances were made for the fact
        that C90 doesn't define long long either.
        Remember that to force cc to use non-builtin standard headers, you need
        to point at these using the -j switch (e.g. -jC:). The only version of
        cc which featured the C90-incompatible stdio.h was 5.70.
        Checked that the header now works when included in -pcc, -c90 and -c99 modes.
      Version 5.81. Tagged as 'RISC_OSLib-5_81'
  35. 21 Jan, 2014 1 commit
    • Robert Sprowson's avatar
      Permit wildcards in RISC_OSLib application's messages files · 76d1dff4
      Robert Sprowson authored
      msgs.c: includes a MessageTrans parser that duplicates MessageTrans_Lookup (needed because the lookup function returns pointers to static C strings). However, did not allow '?' wildcards in the message token names.
      Version 5.80. Tagged as 'RISC_OSLib-5_80'
  36. 20 Jan, 2014 1 commit
    • Jeffrey Lee's avatar
      Fix 32bitification error · a654e89d
      Jeffrey Lee authored
        kernel/s/k_body - At CopyUpDone in _kernel_system(), a big block of conditional code was converted to unconditional as part of the 32bit conversion process. However one line for setting up the error handler remained conditional, potentially preventing the correct error buffer pointer being set when about to start the child task.
        Tested on BB-xM
      Version 5.79. Tagged as 'RISC_OSLib-5_79'
  37. 24 Oct, 2013 1 commit
    • Robert Sprowson's avatar
      Some library fixes · c9b6d7f3
      Robert Sprowson authored
      Fix for problem passing long command lines via system(), while there are good arguments to leave the threshold at 255, non DDEUtils aware programs get brutally truncated command strings, and since the old threshold of 255 applied when the kernel handled 256 command lines, upping the limit to 1k is no worse than before.
      Fix for Edit failing to draw lines of text longer than 192 characters (ticket #350). Several factors were conspiring here: on a mode change the window width in characters wasn't being clamped, whereas user entered limits in the menu were, then the internal buffer ("PAINTBUFSIZE") was too short so lines got truncated, and when larger than 256 got wrapped modulo 256 due to the use of an array of chars. Now set at compile time with BIG_WINDOW_SIZE_LIMIT with a new theoretical maximum of 8192. Currently limited to 480 since it uses stack variables.
      In the C library:
       armsys.c: adapt the threshold at which to use DDEUtils based on the kernel version number
       scanf.c: squash a warning
       time.c: mark the table of month lengths as constant so we can claw back 13 words of static workspace without having to change the stubs
      In RISC OS lib:
       bbc.c: remove local definitions of some SWI numbers
       template.c: squash a warning
       txt.c: delete Modula-2 support
       txt1.c: compare pointer with NULL not an integer
       txtar.c: introduce BIG_WINDOW_SIZE_LIMIT, rationalise a few sprintf's, mark private functions as static
       txtundo.c/txtedit.c: squash old style function warnings
       txtoptmenu.c: clamp the window width read from Edit$Options properly, delete long disabled code
       txtscrap.c: dead function deleted
      Version 5.78. Tagged as 'RISC_OSLib-5_78'
  38. 24 Mar, 2013 1 commit
    • Robert Sprowson's avatar
      Build fix · 8e9a4e8e
      Robert Sprowson authored
      s/h_brazil: use Hdr:System instead of GETting them one at a time
      c/scanf: type cast
      Version 5.77. Tagged as 'RISC_OSLib-5_77'