<?xml version="1.0" encoding="utf-8"?>
<!--RSS generated by Flaimo.com RSS Builder [2026-04-05 10:42:22]-->
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"><channel><docs>https://mantis.ldmud.eu/</docs><link>https://mantis.ldmud.eu/</link><description><![CDATA[MantisBT - Issues]]></description><title>MantisBT - Issues</title><image><title>MantisBT - Issues</title><url>https://mantis.ldmud.eu/images/mantis_logo.png</url><link>https://mantis.ldmud.eu/</link><description><![CDATA[MantisBT - Issues]]></description></image><language>en</language><category>All Projects</category><ttl>10</ttl><dc:language>en</dc:language><sy:updatePeriod>hourly</sy:updatePeriod><sy:updateFrequency>1</sy:updateFrequency><item><title>0000915: SIGSEGV in yyparse/read_jump_offset/get_bc_offset when compiling large LPC with foreach+continue</title><author></author><link>https://mantis.ldmud.eu/view.php?id=915</link><description><![CDATA[Hi team,&lt;br /&gt;
 I was running into a frequent crash when the main living object was compiling, so I used my AI workflow to reproduce it and document. This actual crash is a bit over my head.&lt;br /&gt;
Note that this driver has a few custom add-ins but as far as can be told, they aren't affecting this crash.&lt;br /&gt;
&lt;br /&gt;
 The reproduce example file is atrocious and maybe unnecessary but it's just being used to demonstrate the issue.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Environment&lt;br /&gt;
&lt;br /&gt;
LDMud: 3.6.6 (custom fork)&lt;br /&gt;
Platform: Ubuntu 22.04, x86_64&lt;br /&gt;
Core handling: apport (/var/lib/apport/coredump)&lt;br /&gt;
Summary&lt;br /&gt;
Compiling a large LPC file containing repeated foreach (...) { ... continue; ... } patterns causes a deterministic driver segfault during compile time.&lt;br /&gt;
&lt;br /&gt;
Observed Behavior&lt;br /&gt;
&lt;br /&gt;
Driver crashes with SIGSEGV&lt;br /&gt;
Stack shows:&lt;br /&gt;
get_bc_offset()&lt;br /&gt;
read_jump_offset()&lt;br /&gt;
yyparse() (prolang.y, continue/jump patching path)&lt;br /&gt;
Crash happens while compiling LPC (not runtime execution).&lt;br /&gt;
Expected Behavior&lt;br /&gt;
Compiler should either compile successfully or emit a compile error, never segfault.]]></description><category>LPC Compiler/Preprocessor</category><pubDate>Thu, 26 Mar 2026 20:19:03 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=915</guid><comments>https://mantis.ldmud.eu/view.php?id=915#bugnotes</comments></item><item><title>0000720: Support DTLS (Datagram Transport Layer Security)</title><author></author><link>https://mantis.ldmud.eu/view.php?id=720</link><description><![CDATA[Datagram Transport Layer Security (DTLS) protocol provides communications privacy for datagram protocols. It is based on the stream-oriented TLS protocol and is intended to provide similar security guarantees.&lt;br /&gt;
Since we support TLS for TCP connections, I think we should also support DTLS. This may also open up the possibility to encrypt Intermud traffic transparently at some point in the future.&lt;br /&gt;
&lt;br /&gt;
Unfortunately, DTLS is not widely supported yet. OpenSSL has support for it, but no documentation at all. GnuTLS does not support it (yet?).&lt;br /&gt;
Until that changes or I have much more time to look into the code of OpenSSL (*shudder*), this issue serves just as reminder for the future...]]></description><category>Networking</category><pubDate>Tue, 23 Dec 2025 00:06:17 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=720</guid><comments>https://mantis.ldmud.eu/view.php?id=720#bugnotes</comments></item><item><title>0000908: add_action with some efun operator closure args produces segfault</title><author></author><link>https://mantis.ldmud.eu/view.php?id=908</link><description><![CDATA[I was writing an object that used `add_action` with a closure argument and noticed I could reliably segfault 3.6.7 (also 3.6.6 and 3.6.5) if the initial closure arg to 'efun::add_action' was given a particular efun operator closure as argument, instead of the intended lfun (e.g. because the lfun was accidentally omitted, or had the wrong name).&lt;br /&gt;
&lt;br /&gt;
The choice of efun closure appears to matter. Using a normal efun closure like #'write, or #'notify_fail doesn't crash. Using an operator efun closure like #'switch, #',, or #'= does crash reliably.]]></description><category>Implementation</category><pubDate>Mon, 07 Jul 2025 22:30:58 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=908</guid><comments>https://mantis.ldmud.eu/view.php?id=908#bugnotes</comments></item><item><title>0000914: compile error due to syntax + comment</title><author></author><link>https://mantis.ldmud.eu/view.php?id=914</link><description><![CDATA[Not sure if this is even worth looking into but in the first example when the SET_DATA definition is in use, the error message about the spurious character is misleading, making it difficult to troubleshoot. When the definition isn't used, the error makes sense.&lt;br /&gt;
&lt;br /&gt;
#define SET_DATA(x, y) set_data(x, y)&lt;br /&gt;
&lt;br /&gt;
Line has a typo, missing ) toward the end:	&lt;br /&gt;
 ob-&gt;SET_DATA(&quot;AC&quot;,  CalcAC(ob-&gt;query_all_data(), itembonuses, spellbonuses, aabonuses, 0 /*skip caps*/);&lt;br /&gt;
2024.08.23 13:16:29 daemon/stats_d.c line 1439: Unexpected end of file (or a spurious 0x01 character) before '                  softcap'.&lt;br /&gt;
2024.08.23 13:16:29 daemon/stats_d.c line 1439: syntax error before end of line.&lt;br /&gt;
&lt;br /&gt;
If I don't use the definition:&lt;br /&gt;
	ob-&gt;set_data(&quot;AC&quot;,  CalcAC(ob-&gt;query_all_data(), itembonuses, spellbonuses, aabonuses, 0 /*skip caps*/);&lt;br /&gt;
'.24.08.23 13:21:29 daemon/stats_d.c line 494: syntax error before '&lt;br /&gt;
'.24.08.23 13:21:29 daemon/stats_d.c line 517: syntax error before ';&lt;br /&gt;
'.24.08.23 13:21:29 daemon/stats_d.c line 518: Bad assignment: illegal lhs (target) before '&lt;br /&gt;
2024.08.23 13:21:29 daemon/stats_d.c line 520: Variable level not declared before ' 65) * 5);'.&lt;br /&gt;
2024.08.23 13:21:29 Error in loading object: 'daemon/stats_d'.]]></description><category>LPC Compiler/Preprocessor</category><pubDate>Fri, 23 Aug 2024 17:24:49 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=914</guid><comments>https://mantis.ldmud.eu/view.php?id=914#bugnotes</comments></item><item><title>0000910: libiconv detection broken on MacOS for system version</title><author></author><link>https://mantis.ldmud.eu/view.php?id=910</link><description><![CDATA[The configure check for detection iconv support looks for a symbol libiconv_close which is present in the GNU libiconv, but not in the iconv support by the Systemlib of Macos (and likely also not in (g)libc).&lt;br /&gt;
Workaround is to install a GNU libiconv via macports/fink/homebrew etc.&lt;br /&gt;
&lt;br /&gt;
configure output:&lt;br /&gt;
checking for iconv... yes&lt;br /&gt;
checking if iconv takes a non-const char**... yes&lt;br /&gt;
checking if -liconv is needed... yes&lt;br /&gt;
checking for libiconv_close in -liconv... no&lt;br /&gt;
checking for libiconv_close in -liconv... (cached) no&lt;br /&gt;
&lt;br /&gt;
excerpt from config.log:&lt;br /&gt;
configure:11469: checking for libiconv_close in -liconv&lt;br /&gt;
configure:11498: gcc -o conftest -g -O2 -fwrapv -I/usr/inet6/include   conftest.c -liconv  -lm  &gt;&amp;5&lt;br /&gt;
Undefined symbols for architecture arm64:&lt;br /&gt;
  &quot;_libiconv_close&quot;, referenced from:&lt;br /&gt;
      _main in conftest-e50b42.o&lt;br /&gt;
ld: symbol(s) not found for architecture arm64&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The linker fails later resolving any iconv symbols, because no -liconv is passed. (Unfortunately with a quite misleading error message referencing a specific architecture.)&lt;br /&gt;
&lt;br /&gt;
gcc -O2 -g    access_check.o actions.o applied_decl.o array.o arraylist.o backend.o bitstrings.o call_out.o closure.o comm.o coroutine.o dumpstat.o ed.o efuns.o files.o gcollect.o hash.o heartbeat.o interpret.o lex.o lwobject.o main.o mapping.o md5.o mempools.o mregex.o mstrings.o object.o otable.o parser.o parse.o pkg-iksemel.o pkg-xml2.o pkg-idna.o pkg-mccp.o pkg-mysql.o pkg-gcrypt.o pkg-json.o pkg-python.o pkg-pgsql.o pkg-sqlite.o pkg-tls.o pkg-openssl.o pkg-gnutls.o port.o ptrtable.o random.o regexp.o sha1.o simulate.o simul_efun.o stdstrings.o stdstructs.o strfuns.o structs.o sprintf.o swap.o types.o unidata.o wiz_list.o xalloc.o   -o ldmud -lm   -lsqlite3 -lxml2&lt;br /&gt;
Undefined symbols for architecture arm64:&lt;br /&gt;
  &quot;_iconv&quot;, referenced from:&lt;br /&gt;
      _add_message_text in comm.o&lt;br /&gt;
      _iconv_opt in comm.o&lt;br /&gt;
      _read_file_iconv in files.o&lt;br /&gt;
      _v_write_file in files.o&lt;br /&gt;
      _iconv_opt in files.o&lt;br /&gt;
      __myfilbuf in lex.o&lt;br /&gt;
      _iconv_opt in lex.o&lt;br /&gt;
      ...&lt;br /&gt;
  &quot;_iconv_close&quot;, referenced from:&lt;br /&gt;
      _remove_interactive in comm.o&lt;br /&gt;
      _remove_interactive in comm.o&lt;br /&gt;
      _f_configure_interactive in comm.o&lt;br /&gt;
      _set_encoding in comm.o&lt;br /&gt;
      _set_encoding in comm.o&lt;br /&gt;
      _set_encoding in comm.o&lt;br /&gt;
      _f_configure_driver in efuns.o&lt;br /&gt;
      ...&lt;br /&gt;
  &quot;_iconv_open&quot;, referenced from:&lt;br /&gt;
      _iconv_opt_open in comm.o&lt;br /&gt;
      _set_encoding in comm.o&lt;br /&gt;
      _set_encoding in comm.o&lt;br /&gt;
      _iconv_opt_open in efuns.o&lt;br /&gt;
      _v_read_file in files.o&lt;br /&gt;
      _v_read_file in files.o&lt;br /&gt;
      _get_file_encoding in files.o&lt;br /&gt;
      _get_file_encoding in files.o&lt;br /&gt;
      _get_file_encoding in files.o&lt;br /&gt;
      ...&lt;br /&gt;
ld: symbol(s) not found for architecture arm64]]></description><category>Compilation, Installation</category><pubDate>Sun, 21 Apr 2024 17:26:31 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=910</guid><comments>https://mantis.ldmud.eu/view.php?id=910#bugnotes</comments></item><item><title>0000909: 3.6.7 make error</title><author></author><link>https://mantis.ldmud.eu/view.php?id=909</link><description><![CDATA[Hi. Getting this error on making 3.6.7. See attachment for full output.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
./mk-patchlevel.sh&lt;br /&gt;
3.6.7&lt;br /&gt;
bison --defines=lang.h -o lang.c lang.y&lt;br /&gt;
lang.y:2.9-25: error: %define variable 'api.location.type' is not used&lt;br /&gt;
 %define api.location.type {code_location_t}&lt;br /&gt;
         ^^^^^^^^^^^^^^^^^&lt;br /&gt;
Makefile:214: recipe for target 'lang.h' failed&lt;br /&gt;
make: *** [lang.h] Error 1]]></description><category>Compilation, Installation</category><pubDate>Tue, 26 Dec 2023 05:15:32 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=909</guid><comments>https://mantis.ldmud.eu/view.php?id=909#bugnotes</comments></item><item><title>0000238: Colored string handling</title><author></author><link>https://mantis.ldmud.eu/view.php?id=238</link><description><![CDATA[Short: Useful coloured string efuns&lt;br /&gt;
From:  &quot;Alexander Weidt et al.&quot; &lt;&lt;a href=&quot;mailto:tubmud@cs.tu-berlin.de&quot;&gt;tubmud@cs.tu-berlin.de&lt;/a&gt;&gt;&lt;br /&gt;
Date: Fri Feb 23 13:42:33 2001&lt;br /&gt;
Type: Feature&lt;br /&gt;
New: Acknowledged&lt;br /&gt;
See also: f-011016-0&lt;br /&gt;
&lt;br /&gt;
Hi Lars,,&lt;br /&gt;
&lt;br /&gt;
hier schick ich Dir mal die Klasse basic/coloured_string.c.&lt;br /&gt;
&lt;br /&gt;
Anmerkungen:&lt;br /&gt;
- #define REGEXP_TERMINAL_COLOUR_TOKEN &quot;%\\^([^%]|(%%*[^%^]))*%%*\\^&quot;&lt;br /&gt;
- LIB_CNTL_SEQUENCES-&gt;get_plain_mapping() liefert ein Mapping fuer&lt;br /&gt;
  terminal_colour(), welches alle hier im Mud definierten tokens enthaelt&lt;br /&gt;
  und auf &quot;&quot; abbildet.&lt;br /&gt;
&lt;br /&gt;
Viele Gruesse,&lt;br /&gt;
&lt;br /&gt;
  Coogan.&lt;br /&gt;
-----------------------------------------------------------------------&lt;br /&gt;
/*&lt;br /&gt;
 * /basic/coloured_string.c by Alfe for TubMud 01-Feb-14&lt;br /&gt;
 *&lt;br /&gt;
 * This is a basic class for handling coloured strings.&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
#pragma strong_types&lt;br /&gt;
&lt;br /&gt;
#include &lt;regexps.h&gt;&lt;br /&gt;
#include &lt;libs.h&gt;  // Coogan, 16-Feb-01&lt;br /&gt;
&lt;br /&gt;
private nosave mapping plain_mapping;&lt;br /&gt;
&lt;br /&gt;
/*&lt;br /&gt;
 * this applies `changer' on all parts of the given coloured_string&lt;br /&gt;
 * which are not a colour token and returns the result.&lt;br /&gt;
 */&lt;br /&gt;
string apply_on_coloured_string(string coloured_string,closure changer) {&lt;br /&gt;
  mixed h;&lt;br /&gt;
  int i;&lt;br /&gt;
  h = regexplode(coloured_string,REGEXP_TERMINAL_COLOUR_TOKEN);&lt;br /&gt;
  for (i=0; i&lt;sizeof(h); i+=2)  // pick the non-tokens&lt;br /&gt;
    h[i] = funcall(changer,h[i]);&lt;br /&gt;
  return implode(h,&quot;&quot;);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/*&lt;br /&gt;
 * this removes all colour tokens from the given coloured_string and&lt;br /&gt;
 * returns the result; thus it produces a verbatim string.&lt;br /&gt;
 */&lt;br /&gt;
string to_verbatim(string coloured_string) {&lt;br /&gt;
  if (!plain_mapping)&lt;br /&gt;
    plain_mapping = LIB_CNTL_SEQUENCES-&gt;get_plain_mapping();&lt;br /&gt;
  return terminal_colour(coloured_string,plain_mapping);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/*&lt;br /&gt;
 * this returns the visible string length of a coloured string&lt;br /&gt;
 */&lt;br /&gt;
int strlen_visible(string coloured_string) {&lt;br /&gt;
  if (!plain_mapping)&lt;br /&gt;
    plain_mapping = LIB_CNTL_SEQUENCES-&gt;get_plain_mapping();&lt;br /&gt;
  return strlen(terminal_colour(coloured_string,plain_mapping));&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
private void find_pos(string *parts,&lt;br /&gt;
                      int pos,status pos_from_back,&lt;br /&gt;
                      int real_part,int real_pos,&lt;br /&gt;
                      status as_start) {&lt;br /&gt;
  if (pos_from_back) {&lt;br /&gt;
    if (pos &lt; 0) {&lt;br /&gt;
      real_part = sizeof(parts) - 1;&lt;br /&gt;
      real_pos = strlen(parts[&lt;1]);&lt;br /&gt;
    } else {&lt;br /&gt;
      pos = strlen_visible(implode(parts,&quot;&quot;)) - pos;&lt;br /&gt;
      find_pos(parts,pos,0,&amp;real_part,&amp;real_pos,as_start);&lt;br /&gt;
    }&lt;br /&gt;
  } else {  // from front&lt;br /&gt;
    // skip all parts which are too short:&lt;br /&gt;
    for (real_part = real_pos = 0;&lt;br /&gt;
         real_part &lt; sizeof(parts) &amp;&amp; (as_start?&lt;br /&gt;
                                       pos &gt; strlen(parts[real_part]) :&lt;br /&gt;
                                       pos &gt;= strlen(parts[real_part]));&lt;br /&gt;
         real_pos += strlen(parts[real_part]),&lt;br /&gt;
         pos -= strlen(parts[real_part]),&lt;br /&gt;
         real_part += 2)&lt;br /&gt;
      ;&lt;br /&gt;
    if (real_part &gt;= sizeof(parts)) {  // too long?&lt;br /&gt;
      real_part = sizeof(parts) - 1;&lt;br /&gt;
      real_pos = strlen(parts[&lt;1]);&lt;br /&gt;
    } else&lt;br /&gt;
      real_pos = pos;&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
/*&lt;br /&gt;
 * this returns a substring of the given coloured string;&lt;br /&gt;
 */&lt;br /&gt;
varargs string substring(string coloured_string,&lt;br /&gt;
                         int start,             int stop,&lt;br /&gt;
                         status start_from_back,status stop_from_back) {&lt;br /&gt;
  string *parts;&lt;br /&gt;
  int *real_pos, *vis_pos;&lt;br /&gt;
  int i;&lt;br /&gt;
  int real_start_pos,real_stop_pos;&lt;br /&gt;
  int real_start_part,real_stop_part;&lt;br /&gt;
  parts = regexplode(coloured_string,REGEXP_TERMINAL_COLOUR_TOKEN);&lt;br /&gt;
  find_pos(parts,start,start_from_back,&amp;real_start_part,&amp;real_start_pos,1);&lt;br /&gt;
  find_pos(parts, stop, stop_from_back, &amp;real_stop_part, &amp;real_stop_pos,0);&lt;br /&gt;
  if (real_start_part &gt; real_stop_part)&lt;br /&gt;
    return &quot;&quot;;&lt;br /&gt;
  if (real_start_part == real_stop_part)&lt;br /&gt;
    parts[real_start_part] =&lt;br /&gt;
      parts[real_start_part][real_start_pos..real_stop_pos];&lt;br /&gt;
  else {&lt;br /&gt;
    parts[real_start_part] = parts[real_start_part][real_start_pos..];&lt;br /&gt;
    parts[real_stop_part]  = parts[real_stop_part][..real_stop_pos];&lt;br /&gt;
  }&lt;br /&gt;
  return implode(parts[real_start_part..real_stop_part],&quot;&quot;);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
varargs string coloured_sprintf(string format,varargs mixed *args) {&lt;br /&gt;
  int i;&lt;br /&gt;
  int strlen_diff;&lt;br /&gt;
  for (i=0; i&lt;sizeof(args); i+=2)&lt;br /&gt;
    if (stringp(args[i+1])) {&lt;br /&gt;
      strlen_diff = strlen(args[i+1]) - strlen_visible(args[i+1]);&lt;br /&gt;
      if (args[i] &lt; 0)&lt;br /&gt;
        args[i] -= strlen_diff;&lt;br /&gt;
      else&lt;br /&gt;
        args[i] += strlen_diff;&lt;br /&gt;
    }&lt;br /&gt;
  return apply(#'sprintf,format,args);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Aber gleich zu [] noch was anderes: Wir haben hier die Notwendigkeit&lt;br /&gt;
festgestellt, farbige strings mit terminal_colour()-token an definierten&lt;br /&gt;
Stellen umzubrechen bzw. teilstrings zu extrahieren, und diese Extraktion&lt;br /&gt;
ist in LPC recht teuer.&lt;br /&gt;
&lt;br /&gt;
Dies ist bisher hier so geloest in einer sefun&lt;br /&gt;
subcoloured_string(string coloured_string,&lt;br /&gt;
                   int start,             int stop,&lt;br /&gt;
                   status start_from_back,status stop_from_back):&lt;br /&gt;
&lt;br /&gt;
string s = &quot;%^BOLD_BLUE%^Test%^NORMAL%^ %^RED%^another test%^NORMAL%^&quot;;&lt;br /&gt;
&lt;br /&gt;
subcoloured_string(s, 2)  == &quot;%^BOLD_BLUE%^est%^NORMAL%^ %^RED%^another test%^NORMAL%^&quot;&lt;br /&gt;
s[0..3] == &quot;%^BOLD_BLUE%^Test%^NORMAL%^%^RED%^%^NORMAL%^&quot;&lt;br /&gt;
s[5..]  == &quot;%^BOLD_BLUE%^%^NORMAL%^%^RED%^another test%^NORMAL%^&quot;&lt;br /&gt;
&lt;br /&gt;
D.h. alle Farbtokens bleiben im resultat-string drin, und extrahiert wird&lt;br /&gt;
letztlich der verbatim-teil dazwischen.&lt;br /&gt;
Die sefun zerlegt zunaechst den String in farbtokens und plain text, dann&lt;br /&gt;
wird das extract auf den plaintext-Stuecken vorgenommen, und danach wieder&lt;br /&gt;
der farb-string zusammengesetzt. Wie gesagt, sehr teuer.&lt;br /&gt;
&lt;br /&gt;
Aber hierbei koennen wir wirklich wieder in Probleme laufen, wenn man das&lt;br /&gt;
in [] machen wollte. Ein Datentyp 'coloured_string' waere wirklich nett.&lt;br /&gt;
Und/oder natuerlich eine efun, die diese extrahierung von plain text&lt;br /&gt;
aus colour-token-verseuchten strings vornimmt. :-)&lt;br /&gt;
----------------------------------------------------------------------------&lt;br /&gt;
And Slava wrote in Oct 2001:&lt;br /&gt;
&lt;br /&gt;
Recently I revealed great demand in something like hibrid of&lt;br /&gt;
sprintf+terminal_colour. Also I've discovered, that some time ago&lt;br /&gt;
there was something about this topic - f-990309-1.&lt;br /&gt;
&lt;br /&gt;
In the matter of fact there is a great demand in such a functionality&lt;br /&gt;
in the driver. Till now, there are no official way, how to handle&lt;br /&gt;
coloured strings. I mean, yes you can do something with it - wrap,&lt;br /&gt;
and do very rudimentary formatting, using terminal_colour. But this is&lt;br /&gt;
not enough.&lt;br /&gt;
&lt;br /&gt;
Furthermore, without additional and expensive workarounds, there are no&lt;br /&gt;
way how to:&lt;br /&gt;
&lt;br /&gt;
1. format coloured string like in sprintf(), especially using such a&lt;br /&gt;
   modifiers, like: '-=', '|=', etc.&lt;br /&gt;
2. measure coloured string length like in strlen() or sizeof()&lt;br /&gt;
3. Use all the great funs, that we have for their non-coloured&lt;br /&gt;
   equivalents. All because of there is difference in actual string&lt;br /&gt;
   size and its displayable one.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Subject: sprintf() and colour strings&lt;br /&gt;
From: Lars Duening, Alfe&lt;br /&gt;
Date: 2001-10-16&lt;br /&gt;
Type: Feature&lt;br /&gt;
State: Acknowledged.&lt;br /&gt;
See also: f-010223, f-011015-1, f-000905-1&lt;br /&gt;
&lt;br /&gt;
New format specifier  '%S' to format colour-coded strings, '%s' normal strings&lt;br /&gt;
as usual.&lt;br /&gt;
&lt;br /&gt;
Optionally introduce an efun &lt;br /&gt;
&lt;br /&gt;
  csprintf(mapping cntl, string format, mixed args...)&lt;br /&gt;
&lt;br /&gt;
which first applies sprintf(), and then replaces all colour strings in the&lt;br /&gt;
result before returning it.&lt;br /&gt;
&lt;br /&gt;
Dafire also requested this formatting capability:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
From: &quot;Bastian Hoyer&quot; &lt;&lt;a href=&quot;mailto:dafire@dafire.de&quot;&gt;dafire@dafire.de&lt;/a&gt;&gt;&lt;br /&gt;
Date: Tue, 16 Oct 2001 11:15:39 +0200&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Hallo Lars,&lt;br /&gt;
&lt;br /&gt;
was ich braeuchte waere ein leerzeichen das vorne am Wort klebt :)&lt;br /&gt;
&lt;br /&gt;
also ich mache eine liste die so aussieht:&lt;br /&gt;
&lt;br /&gt;
aaa: +bbb -ccc +ddd  eee  fff&lt;br /&gt;
&lt;br /&gt;
vor jedem wert hab ich ein + oder - oder ein leerzeichen :)&lt;br /&gt;
&lt;br /&gt;
wenn das jetzt umbricht sieht das evtl so aus :&lt;br /&gt;
&lt;br /&gt;
aaa: +bbb -ccc +ddd&lt;br /&gt;
     eee  fff&lt;br /&gt;
&lt;br /&gt;
weil das Leerzeichen vor eee beim umbrechen wegfaellt :)&lt;br /&gt;
&lt;br /&gt;
Ich hoffe das war irgendwie verstaendlich :)&lt;br /&gt;
Ich glaub bei html ist das ein &nbsp; :)&lt;br /&gt;
&lt;br /&gt;
Bastian]]></description><category>Efuns</category><pubDate>Mon, 02 Oct 2023 16:35:30 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=238</guid><comments>https://mantis.ldmud.eu/view.php?id=238#bugnotes</comments></item><item><title>0000865: efun is_typeof() to check if a program is inherited</title><author></author><link>https://mantis.ldmud.eu/view.php?id=865</link><description><![CDATA[Ein Wunsch eines Magiers aus dem MG...&lt;br /&gt;
&lt;br /&gt;
--- cut here ---&lt;br /&gt;
wenn ihr mal wieder am Driver baut: so etwas wie is_typeof(object o, str&lt;br /&gt;
baseloadname) waere cool.&lt;br /&gt;
&lt;br /&gt;
Semantik: &lt;br /&gt;
  return objectp(o) &amp;&amp;&lt;br /&gt;
         member(program_name+&quot;.c&quot;, inherit_list(o))&gt;=0;&lt;br /&gt;
&lt;br /&gt;
Nur halt nicht so teuer :D]]></description><category>LPC Language</category><pubDate>Mon, 02 Oct 2023 16:27:04 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=865</guid><comments>https://mantis.ldmud.eu/view.php?id=865#bugnotes</comments></item><item><title>0000792: limited( expression ... ) would be nice</title><author></author><link>https://mantis.ldmud.eu/view.php?id=792</link><description><![CDATA[Similar to catch( expression )  it would be nice to have a variant of limited() in which one can simply write an expression out.&lt;br /&gt;
&lt;br /&gt;
limited() is hugely helpful for securing critical code, but a limited( expression ... ) variant would help with adoption, as it would make adding a limited() around an expression as easy as adding a catch().&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
BEFORE:&lt;br /&gt;
  err= catch( ob-&gt;fun() )&lt;br /&gt;
&lt;br /&gt;
AFTER (proposed):&lt;br /&gt;
  limited(   err= catch( ob-&gt;fun() )  )]]></description><category>Efuns</category><pubDate>Mon, 02 Oct 2023 16:26:24 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=792</guid><comments>https://mantis.ldmud.eu/view.php?id=792#bugnotes</comments></item><item><title>0000526: Implicit conversions of 64-bit values into 32-bit values</title><author></author><link>https://mantis.ldmud.eu/view.php?id=526</link><description><![CDATA[The gcc in MacOS X 10.5 has a switch for enabling some interesting warnings. -Wshorten-64-to-32 warns about implicit conversions (truncations) of 64-bit values into 32-bit values. This is interesting for people who use the driver on 64-bit platforms, I guess, because this conversion is generally not lossless.&lt;br /&gt;
I learned about this switch today and enabled it to satisfy my curiosity. ;-)&lt;br /&gt;
I got 643 warning during building the driver.&lt;br /&gt;
I will attach the build log to this bug, because I guess, at sometime we have to look into these warning, as that truncations may well cause some bugs and maybe people working on 64-bit platforms want to have a look.]]></description><category>Portability</category><pubDate>Thu, 06 Oct 2022 22:00:38 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=526</guid><comments>https://mantis.ldmud.eu/view.php?id=526#bugnotes</comments></item><item><title>0000325: array index range inconsistency</title><author></author><link>https://mantis.ldmud.eu/view.php?id=325</link><description><![CDATA[Indexing an array by range [x..y] always works, even for negative ranges. However, if you try to assign new values to the indexed part of the array, you get a Lower/Upper range index out of bounds Runtime-Error.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
   &lt;br /&gt;
({0,1,2,3})[-3..1] &lt;br /&gt;
    -&gt; ({0,1})&lt;br /&gt;
    &lt;br /&gt;
({0,1,2,3})[-3..1] = ({4,5})&lt;br /&gt;
    -&gt; Lower range index out of bounds: -3, size: 4.&lt;br /&gt;
&lt;br /&gt;
({0,1,2,3})[2..5] = ({6,7,8})&lt;br /&gt;
    -&gt; Upper range index out of bounds: 5, size: 4.&lt;br /&gt;
&lt;br /&gt;
I like sloppyness (to a certain degree), it's actually sad to see some of it fade away in 3.3. I'm not keen on this half-and-half sloppyness, however. I'd prefer these ranges to work at all times, or never.&lt;br /&gt;
&lt;br /&gt;
Now for something not completely unexpected:&lt;br /&gt;
&lt;br /&gt;
({0,1,2,3})[4..-1] = ({9})&lt;br /&gt;
    -&gt; ({0,1,2,3,9,0,1,2,3})&lt;br /&gt;
&lt;br /&gt;
Where did that 'out of bounds' error go here? And what's with the result? Although the behaviour is half documented, it doesn't make any sense to me.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 21:17:54 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=325</guid><comments>https://mantis.ldmud.eu/view.php?id=325#bugnotes</comments></item><item><title>0000856: Cipher list in tls.h lacks modern ciphers</title><author></author><link>https://mantis.ldmud.eu/view.php?id=856</link><description><![CDATA[Up to date tls libraries like libgnutls or libssl (from openssl) provide ciphers that are not listed in mudlib/sys/tls.h. If the define TLS_CIPHER_NAME(x) is called naively it may choke on a bad index.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 21:00:21 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=856</guid><comments>https://mantis.ldmud.eu/view.php?id=856#bugnotes</comments></item><item><title>0000299: Redesigning mappings, arrays, lvalues</title><author></author><link>https://mantis.ldmud.eu/view.php?id=299</link><description><![CDATA[Short: Redesigning arrays and mappings, and lvalues.&lt;br /&gt;
From: Lars&lt;br /&gt;
Date: 2002-08-13&lt;br /&gt;
Type: Feature&lt;br /&gt;
State: New&lt;br /&gt;
&lt;br /&gt;
The current problem with arrays and mappings is that even though they are&lt;br /&gt;
by-reference objects, they implement it differently. This is most visible&lt;br /&gt;
in the construct lhs += rhs, which for arrays creates a copy of lhs, but not&lt;br /&gt;
for mappings. Reason is that in arrays the data is stored in the array header&lt;br /&gt;
structure, whereas mappings store the data in a separate memory block.&lt;br /&gt;
&lt;br /&gt;
Strings again act like arrays even though they use a separate memory block for&lt;br /&gt;
the data, but otoh they are easy to duplicate and it would be unnatural&lt;br /&gt;
for them to be by-reference datatyps.&lt;br /&gt;
&lt;br /&gt;
Having a by-reference type may feel unusual for programmers coming from other&lt;br /&gt;
languages, but is no functional problem.&lt;br /&gt;
&lt;br /&gt;
Note: Python handles everything by reference. list.append() changes in-place,&lt;br /&gt;
      list + x creates a new list.&lt;br /&gt;
&lt;br /&gt;
Solution 1: Implement the by-reference semantics consequentially&lt;br /&gt;
&lt;br /&gt;
  This means:&lt;br /&gt;
&lt;br /&gt;
  'lhs = rhs1 + rhs2' always creates a new item, copies the content of rhs1&lt;br /&gt;
  and rhs2 into it and then assigns the new item to lhs, freeing whatever&lt;br /&gt;
  was in lhs before.&lt;br /&gt;
&lt;br /&gt;
  'lhs += rhs' takes the contents of rhs and adds them to the existing lhs.&lt;br /&gt;
&lt;br /&gt;
  LPC already has the semantic that lhs[] works directly on the given&lt;br /&gt;
  array/mapping, but it might help if programmers could specify directly&lt;br /&gt;
  that the lhs is to be made duplicated if referenced by more than one&lt;br /&gt;
  owner. For example:&lt;br /&gt;
&lt;br /&gt;
    'unique lhs += rhs' would act like 'lhs = lhs + rhs'&lt;br /&gt;
    'unique lhs[i] = j' would act like 'lhs = copy(lhs); lhs[i] = j'&lt;br /&gt;
&lt;br /&gt;
  'unique' could also be used in a rhs context and would act like copy().&lt;br /&gt;
  The special form 'unique lhs1, lhs2, lhs3,...' would act like&lt;br /&gt;
  'lhs1 = copy(lhs1); lhs2 = copy(lhs2);  lhs3 = lhs(3);'&lt;br /&gt;
&lt;br /&gt;
  In order to implement this efficiently, it might be useful to have a&lt;br /&gt;
  separate svalue type for arrays with fixed number of elements (structs,&lt;br /&gt;
  tuples). Another idea would be to store the initial elements in the array&lt;br /&gt;
  header structure, and let later changes to the array replace the first&lt;br /&gt;
  svalue entry with a special svalue (T_ARRAY_EXTENSION) pointing to the&lt;br /&gt;
  additional data.&lt;br /&gt;
&lt;br /&gt;
  The disadvantage would be that ({}) != ({}) (but ([]) != ([]) already&lt;br /&gt;
  anyway).&lt;br /&gt;
&lt;br /&gt;
Solution 2: Implement a by-value semantics.&lt;br /&gt;
&lt;br /&gt;
  Both 'lhs = rhs1 + rhs2' and 'lhs += rhs' create a new item, copy the&lt;br /&gt;
  content of rhs1 and rhs2 into it and then assigns the new item to lhs,&lt;br /&gt;
  freeing whatever was in lhs before. The advantage of using the '+='&lt;br /&gt;
  operator would be that the interpreter can avoid duplicating lhs&lt;br /&gt;
  if it doesn't have more than one reference.&lt;br /&gt;
&lt;br /&gt;
  To implement this efficiently, the driver would have to implement&lt;br /&gt;
  a copy-on-write semantic.&lt;br /&gt;
&lt;br /&gt;
  To allow the sharing of arrays and mappings, programs would explicitely&lt;br /&gt;
  create references to it, like 'return &amp;foo'. A good implementation of&lt;br /&gt;
  these references would be to use indirection like this:&lt;br /&gt;
&lt;br /&gt;
    type a = value;&lt;br /&gt;
&lt;br /&gt;
      a = (T_TYPE, value)&lt;br /&gt;
&lt;br /&gt;
    type b = &a;&lt;br /&gt;
    type c = &b;&lt;br /&gt;
&lt;br /&gt;
      a = (T_LVALUE)\&lt;br /&gt;
      b = (T_LVALUE)- (3 refs, (T_TYPE, value))&lt;br /&gt;
      c = (T_LVALUE)/&lt;br /&gt;
&lt;br /&gt;
    The lvalue-resolution code would then detect and collapse lvalue&lt;br /&gt;
    holders with only one ref left.&lt;br /&gt;
&lt;br /&gt;
  Handling references to subranges or single elements would require&lt;br /&gt;
  some more effort - views maybe? One view would cache the referenced&lt;br /&gt;
  element and write it back to the underlying structure when the&lt;br /&gt;
  underlying structure as a whole is read, or when another view&lt;br /&gt;
  to the same structure is about to be changed. This would imply a back-&lt;br /&gt;
  pointer from the lvalue-holder to the list of views.&lt;br /&gt;
&lt;br /&gt;
  With this, the language would need a way to ignore the lvalue mode:&lt;br /&gt;
&lt;br /&gt;
    type a = value; type b = &a;&lt;br /&gt;
&lt;br /&gt;
    b = 0; --&gt; removes value from a and b&lt;br /&gt;
    &amp;b = 0; --&gt; removes value from b, but not from a&lt;br /&gt;
    &amp;b = 1; --&gt; just assigns '1' to b, ignores the '&amp;' as b is not an lvalue.&lt;br /&gt;
&lt;br /&gt;
  Another modification would be to allow only read access to the&lt;br /&gt;
  reference: type b = const ref a;]]></description><category>Implementation</category><pubDate>Thu, 06 Oct 2022 20:50:02 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=299</guid><comments>https://mantis.ldmud.eu/view.php?id=299#bugnotes</comments></item><item><title>0000476: Improve eval statistics gathering (patch)</title><author></author><link>https://mantis.ldmud.eu/view.php?id=476</link><description><![CDATA[This patch adds calls to mark_start_evaluation() and mark_end_evaluation() for external master applies, calls to logon() and erq_send callbacks. It also adds a mark_end_evaluation() in the global error handler]]></description><category>Runtime</category><pubDate>Thu, 06 Oct 2022 20:11:50 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=476</guid><comments>https://mantis.ldmud.eu/view.php?id=476#bugnotes</comments></item><item><title>0000146: Filenames in master calls should always start with a leading '/'</title><author></author><link>https://mantis.ldmud.eu/view.php?id=146</link><description><![CDATA[This might break backwards compatibility.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 19:48:14 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=146</guid><comments>https://mantis.ldmud.eu/view.php?id=146#bugnotes</comments></item><item><title>0000907: Disallow addition of empty mappings with different width</title><author></author><link>https://mantis.ldmud.eu/view.php?id=907</link><description><![CDATA[Currently, empty mappings with different widths can be added, e.g. widthof(([:2]) + ([:3])) is 3.&lt;br /&gt;
Non-empty mappings cause a runtime error.&lt;br /&gt;
We currently think, there are no reasonable usecases to be able to add mappings with different widths and would like to disallow them in 3.7.]]></description><category>LPC Language</category><pubDate>Thu, 06 Oct 2022 19:47:03 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=907</guid><comments>https://mantis.ldmud.eu/view.php?id=907#bugnotes</comments></item><item><title>0000158: Add driver compilation options and constants to driver_info()</title><author></author><link>https://mantis.ldmud.eu/view.php?id=158</link><description><![CDATA[We need to&lt;br /&gt;
a) assemble a list of options/constants in config.h.in, machine.h.in, that are useful to have in LPC&lt;br /&gt;
b) add that to driver_info() and maybe even to configure_driver if it should be changed/is changeable.&lt;br /&gt;
&lt;br /&gt;
--- historic description ---&lt;br /&gt;
Short: Runtime query of driver compilation options.&lt;br /&gt;
Date: 981114&lt;br /&gt;
Type: Feature&lt;br /&gt;
State: Proposed&lt;br /&gt;
Long:&lt;br /&gt;
&lt;br /&gt;
The driver should offer a way to query compilation options (like MAX_BITSTRING)&lt;br /&gt;
at runtime, either via LPC-Predefines, or by an efun returning a mapping.]]></description><category>Runtime</category><pubDate>Thu, 06 Oct 2022 19:28:19 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=158</guid><comments>https://mantis.ldmud.eu/view.php?id=158#bugnotes</comments></item><item><title>0000777: Remove memory fragmentation related configuration switches</title><author></author><link>https://mantis.ldmud.eu/view.php?id=777</link><description><![CDATA[It would be nice to remove the following switches (so remove their behaviour OR remove the conditional use): USE_AVL_FREELIST, MALLOC_ORDER_LARGE_FREELISTS and MALLOC_ORDER_SLAB_FREELISTS.&lt;br /&gt;
&lt;br /&gt;
As Gnomi mentioned in &lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=663#c1229&quot; class=&quot;resolved&quot;&gt;0000663:0001229&lt;/a&gt; we should try to measure their impact on fragmentation.&lt;br /&gt;
A possibility for this might be the idea sketched in &lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=663#c1232&quot; class=&quot;resolved&quot;&gt;0000663:0001232&lt;/a&gt;.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 18:40:16 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=777</guid><comments>https://mantis.ldmud.eu/view.php?id=777#bugnotes</comments></item><item><title>0000783: Change documentation to explain small_min_malloc and that it is only used in smalloc</title><author></author><link>https://mantis.ldmud.eu/view.php?id=783</link><description><![CDATA[MIN_SMALL_MALLOCED is used to allocate a certain amount of memory used for small blocks at boot time and reduce memory fragmentation. This is only done for the smalloc allocator, not slaballoc.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 18:34:37 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=783</guid><comments>https://mantis.ldmud.eu/view.php?id=783#bugnotes</comments></item><item><title>0000730: static logon() function does not work for TLS logon callback</title><author></author><link>https://mantis.ldmud.eu/view.php?id=730</link><description><![CDATA[For a standard connect logon() in the login object can be static.&lt;br /&gt;
&lt;br /&gt;
If tls_init_connection() is called in connect() in the master, the call to logon() in the login object is delayed until TLS handshake finished and the logon() is called. In this case, logon() must not be static. This inconsistency is a bit annoying, especially because it is not documented.&lt;br /&gt;
&lt;br /&gt;
However, because arbitrary callbacks can be defined with tls_init_connection(), we can't simply ignore any access modifiers when executing the callback.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 18:16:39 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=730</guid><comments>https://mantis.ldmud.eu/view.php?id=730#bugnotes</comments></item><item><title>0000696: Change some efuns to return structs</title><author></author><link>https://mantis.ldmud.eu/view.php?id=696</link><description><![CDATA[LDMud recently gained the capability to return structs from efuns.&lt;br /&gt;
&lt;br /&gt;
We now need to define which efuns should be changed in 3.7.x.&lt;br /&gt;
Ideas: driver_info (DI_TRACE), ...?&lt;br /&gt;
&lt;br /&gt;
--- historic/obsolete description ---&lt;br /&gt;
 thought today of efuns returning structs.&lt;br /&gt;
Usually we return arrays, if efuns return more than one value. But struct are nice as well (nearly as fast, but typed). I could imagine it for efuns like object_info(), driver_info(), query_limits(), call_out_info() and such...&lt;br /&gt;
&lt;br /&gt;
As far as I can see: returning structs is not a big problem (now that they are not optional anymore), but returning anonymous structs is not better than arrays. So, we would the type definitions for these structs independent of a specific program being loaded...&lt;br /&gt;
&lt;br /&gt;
Some ideas: kind of simul_efun for structs? Or struct-preloads? Then we would have to supply the right struct types in LPC (write them on-the-fly?) or have them implicitly defined and 'inherited' by any program...]]></description><category>Compilation, Installation</category><pubDate>Thu, 06 Oct 2022 17:59:35 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=696</guid><comments>https://mantis.ldmud.eu/view.php?id=696#bugnotes</comments></item><item><title>0000664: RfC: Remove compat mode</title><author></author><link>https://mantis.ldmud.eu/view.php?id=664</link><description><![CDATA[The efun transfer() might be emulated by a simul-efun. But the biggest problem is, that in compat mode all file and object names don't have a leading slash.]]></description><category>General</category><pubDate>Thu, 06 Oct 2022 17:48:26 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=664</guid><comments>https://mantis.ldmud.eu/view.php?id=664#bugnotes</comments></item><item><title>0000294: Range operator in mappings</title><author></author><link>https://mantis.ldmud.eu/view.php?id=294</link><description><![CDATA[Short: Range operators on 2d mappings&lt;br /&gt;
From: Lars&lt;br /&gt;
Date: 2002-05-07&lt;br /&gt;
Type: Feature&lt;br /&gt;
State: New&lt;br /&gt;
&lt;br /&gt;
m = ([ &quot;foo&quot;: 2; 3; 4, &quot;spot&quot;: 7; 8; 9 ]);&lt;br /&gt;
&lt;br /&gt;
m[&quot;spot&quot;,0..1] --&gt; ({ 7, 8 })&lt;br /&gt;
&lt;br /&gt;
It could be implemented such that m[&quot;spot&quot;,&lt;range&gt;] always returns a flat copy of the values in the mapping.]]></description><category>LPC Compiler/Preprocessor</category><pubDate>Mon, 19 Sep 2022 22:47:31 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=294</guid><comments>https://mantis.ldmud.eu/view.php?id=294#bugnotes</comments></item><item><title>0000753: Ranged mapping indexing</title><author></author><link>https://mantis.ldmud.eu/view.php?id=753</link><description><![CDATA[I'd like to propose ranged mapping indexing, allowing wide mapping values to be accessed as an array.  For instance;&lt;br /&gt;
&lt;br /&gt;
mapping map1 = ([ &quot;a&quot;: 1; 2; 3, ]);&lt;br /&gt;
&lt;br /&gt;
printf(&quot;%Q\n%Q\n&quot;, map1[&quot;a&quot;, 0..2], map1[&quot;a&quot;, &lt;2..]);&lt;br /&gt;
&lt;br /&gt;
Additionally, it would be a natural extension to use these as l-values, so -&lt;br /&gt;
&lt;br /&gt;
map1[&quot;b&quot;, 1..2] = ({ 4, 5, });&lt;br /&gt;
&lt;br /&gt;
Coping mapping values from one mapping to another would become a lot easier -&lt;br /&gt;
&lt;br /&gt;
map2[&quot;c&quot;, ..] = map1[&quot;a&quot;, ..];&lt;br /&gt;
&lt;br /&gt;
As for the closure versions of these operators, I'd suggest reusing the existing ranged closures (#'[..], #'[&lt;..], #'[..&lt;], #'[&lt;..&lt;]), accepting an additional argument as the mapping key -&lt;br /&gt;
&lt;br /&gt;
funcall(#'[..], map1, &quot;a&quot;, 0, 2) == map[&quot;a&quot;, 0..2]);&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I think this would be a logical extension to the language, making wide mappings easier to manipulate.  However, I understand how much time these things take and I'd like to express my gratitude for the work being done and to all contributors.]]></description><category>General</category><pubDate>Mon, 19 Sep 2022 22:46:36 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=753</guid><comments>https://mantis.ldmud.eu/view.php?id=753#bugnotes</comments></item><item><title>0000902: LDMud 3.6.5 python initialization time object reference crash</title><author></author><link>https://mantis.ldmud.eu/view.php?id=902</link><description><![CDATA[With LDMud 3.6.4 with Python support compiled in it was possible to have a `--python-script` argument that used `import ldmud; ldmud.Object(&quot;/some/path.c&quot;)` to get a reference to an LPC object, even while the early driver initialization is occurring and the master object is not available.&lt;br /&gt;
&lt;br /&gt;
With LDMud 3.6.5 the same Python startup script causes a reliable segfault. In &quot;Steps to Reproduce&quot; I've included a built binary and core dump from a representative segfault.&lt;br /&gt;
&lt;br /&gt;
This appears to be due to a the `current_ob` being `NULL` before master has been initialized. This in turn causes a call to `ldmud_object_create` to use `NULL` as an argument to `ref_object`, causing a panic. &lt;br /&gt;
&lt;br /&gt;
Here is a GDB session with a backtrace:&lt;br /&gt;
```&lt;br /&gt;
&lt;a href=&quot;mailto:mud@windmill2&quot;&gt;mud@windmill2&lt;/a&gt;:~/dunenextnext/ldmud-3.6.5/test$ gdb --args ../src/ldmud -u-1 -E 0 --no-compat -e -N --cleanup-time -1 --reset-time -1 --max-array 0 --max-callouts 0 --max-bytes 0 --max-file 0 -s-1 -sv-1 --hard-malloc-limit unlimited --min-malloc 0 -ru0 -rm0 -rs0 --no-strict-euids --no-wizlist-file --check-refcounts --check-state 2 --access-file none --access-log none -f test --python-script startup.py -Mmaster -mt-python 65432 --debug-file ../log/result.t-python.log&lt;br /&gt;
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2&lt;br /&gt;
Copyright (C) 2020 Free Software Foundation, Inc.&lt;br /&gt;
License GPLv3+: GNU GPL version 3 or later &lt;&lt;a href=&quot;http://gnu.org/licenses/gpl.html&gt;&quot; rel=&quot;noopener&quot;&gt;http://gnu.org/licenses/gpl.html&gt;&lt;/a&gt;&lt;br /&gt;
This is free software: you are free to change and redistribute it.&lt;br /&gt;
There is NO WARRANTY, to the extent permitted by law.&lt;br /&gt;
Type &quot;show copying&quot; and &quot;show warranty&quot; for details.&lt;br /&gt;
This GDB was configured as &quot;x86_64-linux-gnu&quot;.&lt;br /&gt;
Type &quot;show configuration&quot; for configuration details.&lt;br /&gt;
For bug reporting instructions, please see:&lt;br /&gt;
&lt;&lt;a href=&quot;http://www.gnu.org/software/gdb/bugs/&gt;&quot; rel=&quot;noopener&quot;&gt;http://www.gnu.org/software/gdb/bugs/&gt;.&lt;/a&gt;&lt;br /&gt;
Find the GDB manual and other documentation tgresources online at:&lt;br /&gt;
    &lt;&lt;a href=&quot;http://www.gnu.org/software/gdb/documentation/&gt;&quot; rel=&quot;noopener&quot;&gt;http://www.gnu.org/software/gdb/documentation/&gt;.&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
For help, type &quot;help&quot;.&lt;br /&gt;
Type &quot;apropos word&quot; to search for commands related to &quot;word&quot;...&lt;br /&gt;
Reading symbols from ../src/ldmud...&lt;br /&gt;
warning: File &quot;/home/mud/dunenextnext/ldmud-3.6.5/src/ldmud-gdb.py&quot; auto-loading has been declined by your `auto-load safe-path' set to &quot;$debugdir:$datadir/auto-load&quot;.&lt;br /&gt;
To enable execution of this file add&lt;br /&gt;
	add-auto-load-safe-path /home/mud/dunenextnext/ldmud-3.6.5/src/ldmud-gdb.py&lt;br /&gt;
line to your configuration file &quot;/home/mud/.gdbinit&quot;.&lt;br /&gt;
To completely disable this security protection add&lt;br /&gt;
	set auto-load safe-path /&lt;br /&gt;
line to your configuration file &quot;/home/mud/.gdbinit&quot;.&lt;br /&gt;
For more information about this security protection see the&lt;br /&gt;
&quot;Auto-loading safe path&quot; section in the GDB manual.  E.g., run from the shell:&lt;br /&gt;
	info &quot;(gdb)Auto-loading safe path&quot;&lt;br /&gt;
(gdb) run&lt;br /&gt;
Starting program: /home/mud/dunenextnext/ldmud-3.6.5/src/ldmud -u-1 -E 0 --no-compat -e -N --cleanup-time -1 --reset-time -1 --max-array 0 --max-callouts 0 --max-bytes 0 --max-file 0 -s-1 -sv-1 --hard-malloc-limit unlimited --min-malloc 0 -ru0 -rm0 -rs0 --no-strict-euids --no-wizlist-file --check-refcounts --check-state 2 --access-file none --access-log none -f test --python-script startup.py -Mmaster -mt-python 65432 --debug-file ../log/result.t-python.log&lt;br /&gt;
[Thread debugging using libthread_db enabled]&lt;br /&gt;
Using host libthread_db library &quot;/lib/x86_64-linux-gnu/libthread_db.so.1&quot;.&lt;br /&gt;
2022.01.11 02:10:38 LDMud 3.6.5 (3.6.5-1-gd8f1ef68) (development)&lt;br /&gt;
2022.01.11 02:10:38 Seeding PRNG from /dev/urandom.&lt;br /&gt;
2022.01.11 02:10:38 TLS: (OpenSSL) x509 keyfile '/home/mud/dunenextnext/certs/privkey.pem', certfile '/home/mud/dunenextnext/certs/fullchain.pem'&lt;br /&gt;
2022.01.11 02:10:38 TLS: (OpenSSL) X509 certificate from '/home/mud/dunenextnext/certs/fullchain.pem': B3:99:2B:EC:AD:C2:AE:1C:E6:64:C1:34:97:69:F6:C8:65:63:6F:21&lt;br /&gt;
2022.01.11 02:10:38 TLS: (OpenSSL) trusted x509 certificates from '/home/mud/dunenextnext/certs/fullchain.pem'.&lt;br /&gt;
2022.01.11 02:10:38 TLS: Importing built-in default DH parameters.&lt;br /&gt;
2022.01.11 02:10:38 mySQL 8.0.27&lt;br /&gt;
&lt;br /&gt;
Program received signal SIGSEGV, Segmentation fault.&lt;br /&gt;
ldmud_object_create (ob=0x0) at pkg-python.c:2943&lt;br /&gt;
2943	    self-&gt;lpc_object = ref_object(ob, &quot;ldmud_object_create&quot;);&lt;br /&gt;
(gdb) bt&lt;br /&gt;
#0  ldmud_object_create (ob=0x0) at pkg-python.c:2943&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=1&quot;&gt;0000001&lt;/a&gt;  0x000055555565beca in svalue_to_python (svp=0x7fffffffc710) at pkg-python.c:9322&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=2&quot;&gt;0000002&lt;/a&gt;  python_save_contextvar_value (contextvar=0x5555557b9c08 &lt;python_contextvar_current_object&gt;,&lt;br /&gt;
    name=0x5555556c9dbd &quot;ldmud.current_object&quot;, object=...) at pkg-python.c:9832&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=3&quot;&gt;0000003&lt;/a&gt;  python_save_context () at pkg-python.c:9857&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=4&quot;&gt;0000004&lt;/a&gt;  0x0000555555660fc5 in python_call_hook_object (hook=1, is_external=&lt;optimized out&gt;, ob=0x7ffff6440b80)&lt;br /&gt;
    at pkg-python.c:10410&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=5&quot;&gt;0000005&lt;/a&gt;  0x0000555555619b4a in init_object_variables (&lt;a href=&quot;mailto:ob=ob@entry&quot;&gt;ob=ob@entry&lt;/a&gt;=0x7ffff6440b80, &lt;a href=&quot;mailto:templ=templ@entry&quot;&gt;templ=templ@entry&lt;/a&gt;=0x0) at object.c:494&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=6&quot;&gt;0000006&lt;/a&gt;  0x000055555566ed22 in load_object (&lt;a href=&quot;mailto:lname=lname@entry&quot;&gt;lname=lname@entry&lt;/a&gt;=0x7ffff644ad20 &quot;a&quot;, &lt;a href=&quot;mailto:create_super=create_super@entry&quot;&gt;create_super=create_super@entry&lt;/a&gt;=false,&lt;br /&gt;
    &lt;a href=&quot;mailto:depth=depth@entry&quot;&gt;depth=depth@entry&lt;/a&gt;=0, &lt;a href=&quot;mailto:isMasterObj=isMasterObj@entry&quot;&gt;isMasterObj=isMasterObj@entry&lt;/a&gt;=false, &lt;a href=&quot;mailto:chain=chain@entry&quot;&gt;chain=chain@entry&lt;/a&gt;=0x0) at simulate.c:2236&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=7&quot;&gt;0000007&lt;/a&gt;  0x000055555566c443 in lookfor_object (str=&lt;optimized out&gt;, &lt;a href=&quot;mailto:bLoad=bLoad@entry&quot;&gt;bLoad=bLoad@entry&lt;/a&gt;=true) at simulate.c:2538&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=8&quot;&gt;0000008&lt;/a&gt;  0x0000555555651a25 in ldmud_object_init_getobject (&lt;a href=&quot;mailto:num_arg=num_arg@entry&quot;&gt;num_arg=num_arg@entry&lt;/a&gt;=0, &lt;a href=&quot;mailto:data=data@entry&quot;&gt;data=data@entry&lt;/a&gt;=0x7fffffffcaa0)&lt;br /&gt;
    at pkg-python.c:2600&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=9&quot;&gt;0000009&lt;/a&gt;  0x000055555565c0e9 in call_lpc_secure (&lt;a href=&quot;mailto:fun=fun@entry&quot;&gt;fun=fun@entry&lt;/a&gt;=0x555555651a10 &lt;ldmud_object_init_getobject&gt;,&lt;br /&gt;
    &lt;a href=&quot;mailto:num_arg=num_arg@entry&quot;&gt;num_arg=num_arg@entry&lt;/a&gt;=0, &lt;a href=&quot;mailto:data=data@entry&quot;&gt;data=data@entry&lt;/a&gt;=0x7fffffffcaa0) at pkg-python.c:9759&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=10&quot;&gt;0000010&lt;/a&gt; 0x000055555565c59a in ldmud_object_init (self=0x7ffff5de3540, args=&lt;optimized out&gt;, kwds=&lt;optimized out&gt;)&lt;br /&gt;
    at pkg-python.c:2632&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=11&quot;&gt;0000011&lt;/a&gt; 0x00007ffff6edd199 in ?? () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=12&quot;&gt;0000012&lt;/a&gt; 0x00007ffff6f3cafb in _PyObject_MakeTpCall () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
&lt;a href=&quot;https://mantis.ldmud.eu/view.php?id=13&quot;&gt;0000013&lt;/a&gt; 0x00007ffff6d08df3 in ?? () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#14 0x00007ffff6d10ef6 in _PyEval_EvalFrameDefault () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#15 0x00007ffff6e5eecb in _PyEval_EvalCodeWithName () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#16 0x00007ffff6e5f252 in PyEval_EvalCodeEx () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#17 0x00007ffff6e5f63f in PyEval_EvalCode () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#18 0x00007ffff6e200dc in ?? () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#19 0x00007ffff6e21a47 in PyRun_SimpleFileExFlags () from /lib/x86_64-linux-gnu/libpython3.8.so.1.0&lt;br /&gt;
#20 0x000055555565faf6 in pkg_python_init (prog_name=&lt;optimized out&gt;) at pkg-python.c:9987&lt;br /&gt;
#21 0x0000555555571b52 in main (argc=&lt;optimized out&gt;, argv=0x7fffffffe158) at main.c:581&lt;br /&gt;
```]]></description><category>Runtime</category><pubDate>Mon, 19 Sep 2022 22:46:25 +0000</pubDate><guid>https://mantis.ldmud.eu/view.php?id=902</guid><comments>https://mantis.ldmud.eu/view.php?id=902#bugnotes</comments></item></channel></rss>
