pike issueshttps://git.lysator.liu.se/pikelang/pike/-/issues2020-02-29T18:04:27Zhttps://git.lysator.liu.se/pikelang/pike/-/issues/996Line numbers get wrong2020-02-29T18:04:27ZPeter BortasLine numbers get wrongImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=996
Reported by Martin Stjernholm <mast@roxen.com>
The backtrace produced by the following program complains on line 6, while
in reality the error gets thrown from line 9...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=996
Reported by Martin Stjernholm <mast@roxen.com>
The backtrace produced by the following program complains on line 6, while
in reality the error gets thrown from line 9. Altering the text in the
argument to either macro, e.g. by inserting a space, makes the backtrace
report the correct line.
```
#define ASSERT(foo) if (!(foo)) error ("Assertion failed: " # foo "\n")
```
int main()
{
if (0) {
ASSERT (0 == 1); // Line 6
}
else {
ASSERT (0 == 1); // Line 9
}
}Pike 7.2Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/1919inf and nan floats doesn't encode_value2020-03-01T13:09:44ZPeter Bortasinf and nan floats doesn't encode_valueImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=1919
Reported by Mirar , Idonex Heavy Industries <mirar@roxen.com>
```
> Math.nan; decode_value(encode_value(Math.nan));
Result: nan
Result: -2.000000
> Math.inf; decode_...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=1919
Reported by Mirar , Idonex Heavy Industries <mirar@roxen.com>
```
> Math.nan; decode_value(encode_value(Math.nan));
Result: nan
Result: -2.000000
> Math.inf; decode_value(encode_value(Math.inf));
Result: inf
Result: -2.000000
```
Suggested solution: Encode floats using IEEE standard (suitable size, 64
bits if pike is using doubles). Let people who need backwards-compatible
encode_value use a backwards_compatible_encode_value function or similar.Pike 7.4Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/1279Segfault on exit2020-03-01T13:34:24ZPeter BortasSegfault on exitImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=1279
Reported by Stefan Berndtsson, GU <stefan@nocrew.org>
When compiling 7.2 (and 7.3) on Linux/PPC (running Debian), it compiles
fine, but when pike is being run (like ...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=1279
Reported by Stefan Berndtsson, GU <stefan@nocrew.org>
When compiling 7.2 (and 7.3) on Linux/PPC (running Debian), it compiles
fine, but when pike is being run (like in "make verify"), it always exits
with a Segmentation Fault. This does not happen on Linux/x86 with the same
source. Both CVS and D.Hedbor's latest snapshots have been tested.
A quick backtrace from GDB looks like this:
```
$ ulimit -c unlimited
$ ./test-pike
Pike v7.3 release 2 running Hilfe v2.0 (Incremental Pike Frontend)
> exit(1);
Segmentation fault (core dumped)
$ gdb ./test-pike core
GNU gdb 5.0
[..snipped license stuff..]
(gdb) bt
#0 0xfe634e4 in __deregister_frame_info () from /lib/libc.so.6
#1 0xffbabc0 in dlopen () from /lib/libm.so.6
#2 0xffd545c in llroundf () from /lib/libm.so.6
#3 0x3000f130 in _dl_fini () at dl-fini.c:170
#4 0xfd95d8c in exit () from /lib/libc.so.6
#5 0x1007adc8 in low_init_main ()
#6 0x1007ad84 in pike_do_exit ()
#7 0xfd7fe68 in __libc_start_main () from /lib/libc.so.6
```
The current libc used is debian's 2.2.2-1 but 2.1.3-13 has been tested with
the same result.Pike 7.2Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/2589Pike 7.4 superbug2020-03-01T13:36:41ZPeter BortasPike 7.4 superbugImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2589
Reported by Martin Nilsson, IDA <nilsson@pike.ida.liu.se>
Let this bug depend on blocker bugs for Pike 7.4.Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2589
Reported by Martin Nilsson, IDA <nilsson@pike.ida.liu.se>
Let this bug depend on blocker bugs for Pike 7.4.Pike 7.6https://git.lysator.liu.se/pikelang/pike/-/issues/2094optional modifier fails2020-03-01T13:40:46ZPeter Bortasoptional modifier failsImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2094
Reported by Martin Nilsson, IDA <nilsson@pike.ida.liu.se>
The code
```
class MyFont {
inherit Image.Font;
optional string _sprintf() {
return "MyFont";
}...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2094
Reported by Martin Nilsson, IDA <nilsson@pike.ida.liu.se>
The code
```
class MyFont {
inherit Image.Font;
optional string _sprintf() {
return "MyFont";
}
}
MyFont stuff() {
return Image.Font();
}
```
fails with
```
bash-2.03$ /export/d1/nilsson/pike/7.2.166/bin/pike test.pike
test.pike:11:Wrong return type.
test.pike:11:Expected: object(implements 65585)
test.pike:11:Got : object(is 65590)
test.pike:11:Missing identifier "_sprintf".
Pike: Failed to compile script:
Compilation failed.
bash-2.03$ /export/d1/nilsson/pike/7.3.11/bin/pike test.pike
test.pike:11:Wrong return type.
test.pike:11:Expected: { MyFont = object(implements 65601) }
test.pike:11:Got : object(is 103)
test.pike:11:Missing identifier "_sprintf".
Pike: Failed to compile script:
Compilation failed.
```Pike 7.4Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/2861One hour offset in If-Modified-Since header.2020-03-01T13:52:24ZPeter BortasOne hour offset in If-Modified-Since header.Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2861
Reported by Arjan van Staalduijnen, RTL iMedia <arjanvanstaalduijnen@rtlimedia.nl>
The If-Modified-Since header does not use the correct time to determine
of the pag...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2861
Reported by Arjan van Staalduijnen, RTL iMedia <arjanvanstaalduijnen@rtlimedia.nl>
The If-Modified-Since header does not use the correct time to determine
of the page has been modified.
If for a page a Last-Modified header is reported like
Last-Modified: Thu, 14 Mar 2002 14:50:59 GMT
and a request for this page is done with a header
If-Modified-Since: Thu, 14 Mar 2002 14:50:59 GMT
a 304 result should be returned. Instead a 200 result is returned. If a
request is done for the same page, where the If-Modified-Since header
states a time, one hour later (so, Thu, Mar 14 2002 15:50:59 GMT) a 304
is indeed returned. Anything earlier than that one hour offset returns a
200 result.Pike 7.0Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/2726Line number bug (not shared nodes related)2020-03-01T13:53:50ZPeter BortasLine number bug (not shared nodes related)Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2726
Reported by Martin Stjernholm <mast@roxen.com>
In this program, Pike reports the error on the line indicated with the
comment:
```
mixed foo;
array bar = ({...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2726
Reported by Martin Stjernholm <mast@roxen.com>
In this program, Pike reports the error on the line indicated with the
comment:
```
mixed foo;
array bar = ({});
int main()
{
int i = 1;
if (i) {
foo = bar[i];
}
} // Attempt to index the empty array with 1.
```
The problem is the same whether or not shared nodes are enabled. It's
interesting that the problem disappears if the variable i isn't function
local, or if bar is replaced by a literal ({}) but not if it's made
constant.
The problem does not exist in 7.2 and earlier. Tested in a Pike compiled
without machine code.Pike 7.4Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/2677weirdness w/ternary operator (a?b:c)2020-03-01T14:02:15ZPeter Bortasweirdness w/ternary operator (a?b:c)Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2677
Reported by Martin Stjernholm <mast@roxen.com>
```
From: "Robert J. Budzynski" <Robert.Budzynski@fuw.edu.pl>
Subject: weirdness w/ternary operator (a?b:c)
To: pike@r...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=2677
Reported by Martin Stjernholm <mast@roxen.com>
```
From: "Robert J. Budzynski" <Robert.Budzynski@fuw.edu.pl>
Subject: weirdness w/ternary operator (a?b:c)
To: pike@roxen.com
Date: Sun Jan 13 02:12:14 2002 +0100
Pike v7.2 release 234 running Hilfe v2.0 (Incremental Pike Frontend)
> mixed foo(mixed x){return x?(write("FOO\n"),"FOO"):werror("BAR\n");}
> foo(1);
FOO
Result: 1
> foo(0);
BAR
Result: 0
> mixed fooo(mixed x){return
x?(write("FOO\n"),"FOO"):(werror("BAR\n"),"BAR");}
> fooo(0);
BAR
Result: "BAR"
> fooo(1);
FOO
Result: "FOO"
```
Note that while fooo() works correctly, the return value of foo(1) is
bogus. Pike is getting confused when the third arg of the ternary operator
(the `c' in a?b:c) is a call to a function of return type void.Pike 7.2Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/3924Modules using CMOD can't be compiled.2020-03-01T14:47:33ZPeter BortasModules using CMOD can't be compiled.Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=3924
Reported by Adam Montague, Sirius Hosting <amontague@siriushosting.com>
It appears as though any modules using CMOD (including one I am writing
myself) cannot compil...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=3924
Reported by Adam Montague, Sirius Hosting <amontague@siriushosting.com>
It appears as though any modules using CMOD (including one I am writing
myself) cannot compile. If I switch my module to just using a .c source
file it works fine, but if I use a .cmod file I get:
make PIKE_INCLUDES=-I/usr/local/include/pike PIKE_SRC_DIR=/usr/local/
include/pike BUILD_BASE=/usr/local/include/pike MODULE_BASE=/usr/local/
include/pike TMP_BINDIR=/usr/local/include/pike SRCDIR=. FULL_SRCDIR=/home/
adam/pike-fcgi/ TMP_MODULE_BASE=. PIKE_EXTERNAL_MODULE=pike_external_module
CORE_AUTODOC_PATH=/usr/local/lib/doc/src/core_autodoc.xml SYSTEM_DOC_PATH=/
usr/local/lib/doc/ SYSTEM_MODULE_PATH=/usr/local/lib/pike/modules
LOCAL_MODULE_PATH=$$HOME/lib/pike/modules RUNPIKE=pike depend
make: don't know how to make /usr/local/include/pike/precompile.sh-stamp
creating an empty /usr/local/include/pike/precompile.sh-stamp allows the
modules to compile.Pike 7.6Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/3948GLUT module dependencies fail on Mac OS X.3.92020-03-01T14:50:48ZPeter BortasGLUT module dependencies fail on Mac OS X.3.9Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=3948
Reported by Hermann Kruud, <hermannkruud@yahoo.co.uk>
When building Pike v7.7 release 21 (also v7.6 release 24 and v7.4 release
25) on Mac OS X.3.9 the output regard...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=3948
Reported by Hermann Kruud, <hermannkruud@yahoo.co.uk>
When building Pike v7.7 release 21 (also v7.6 release 24 and v7.4 release
25) on Mac OS X.3.9 the output regarding the GLUT module is:
configure: configuring in GLUT
configure: running /bin/bash -norc
'/Users/kruud/Sources/Pike/7.7/src/post_modules/GLUT/configure'
--prefix=/usr/local/pike '--prefix=/usr/local/pike' '--with-debug'
'CC=/usr/bin/gcc' 'CFLAGS=-I/sw/include -I/usr/X11R6/include
-I/usr/local/include' 'CPPFLAGS=-I/sw/include -I/usr/X11R6/include
-I/usr/local/include' 'LDFLAGS=-L/sw/lib -L/usr/X11R6/lib -L/usr/local/lib'
'--cache-file=.././config.cache'
'--srcdir=/Users/kruud/Sources/Pike/7.7/src/post_modules'
--cache-file=../.././config.cache
--srcdir=/Users/kruud/Sources/Pike/7.7/src/post_modules/GLUT
configure: loading cache ../.././config.cache
###################################################
## Configuring module: GLUT
## Installation dir:
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... (cached) o
checking whether we are using the GNU C compiler... (cached) yes
checking whether /Users/kruud/Sources/Pike/7.7/bin/smartlink
/usr/bin/gcc accepts -g... (cached) yes
checking for /Users/kruud/Sources/Pike/7.7/bin/smartlink /usr/bin/gcc
option to accept ANSI C... (cached) none needed
checking if we are using TCC (TenDRA C Compiler)... (cached) no
checking how to run the C preprocessor... /usr/bin/gcc -E
checking for X... (cached) libraries /usr/X11R6/lib, headers
/usr/X11R6/include
checking for egrep... (cached) grep -E
checking for ANSI C header files... (cached) yes
checking for sys/types.h... (cached) yes
checking for sys/stat.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for memory.h... (cached) yes
checking for strings.h... (cached) yes
checking for inttypes.h... (cached) yes
checking for stdint.h... (cached) yes
checking for unistd.h... (cached) yes
checking for gnu/stubs.h... (cached) no
checking for gethostbyname... (cached) yes
checking for connect... (cached) yes
checking for remove... (cached) yes
checking for shmat... (cached) yes
checking for IceConnectionNumber in -lICE... (cached) yes
X_CFLAGS: -I/usr/X11R6/include
X_LIBS: -L/usr/X11R6/lib
X_EXTRA_LIBS:
X_PRE_LIBS: -lSM -lICE
checking GL/glut.h usability... yes
checking GL/glut.h presence... yes
checking for GL/glut.h... yes
checking GLUT/glut.h usability... yes
checking GLUT/glut.h presence... yes
checking for GLUT/glut.h... yes
checking for XDrawPoint in -lX11... yes
checking for XShmPutImage in -lXext... yes
checking for XmuStandardColormap in -lXmu... yes
checking for glOrtho in -lGL... yes
checking for glOrtho in -lOpenGL... no
checking for glOrtho in -lMesaGL... no
checking for gluCylinder in -lGLU... yes
checking for gluCylinder in -lMesaGLU... no
checking for XOpenDevice in -lXinput... no
checking for XOpenDevice in -lXi... yes
checking for glutSolidTeapot in -lglut... no
checking for glutSolidTeapot in GLUT.framework... no
checking for glutEnterGameMode... no
checking for glutForceJoystickFunc... no
checking for glutGameModeGet... no
checking for glutGameModeString... no
checking for glutIgnoreKeyRepeat... no
checking for glutInitDisplayString... no
checking for glutJoystickFunc... no
checking for glutKeyboardUpFunc... no
checking for glutLeaveGameMode... no
checking for glutPostWindowOverlayRedisplay... no
checking for glutPostWindowRedisplay... no
checking for glutReportErrors... no
checking for glutSetKeyRepeat... no
checking for glutSpecialUpFunc... no
checking whether make sets $(MAKE)... (cached) yes
checking for the Pike base directory... /Users/kruud/Sources/Pike/7.7/src
updating cache ../.././config.cache
configure: creating ./config.status
config.status: creating make_variables
config.status: creating Makefile
config.status: creating config.h
config.status: executing default commands
Eventually the GLUT module doesn't compile:
GLUT................ no (dependencies failed)Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4156problem with redefine "`<<" and "`>>" operation2020-03-01T14:55:29ZPeter Bortasproblem with redefine "`<<" and "`>>" operationImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4156
Reported by Andrew Shirrayev, <andrews@gate.ort.spb.ru>
```
$ pike7.6 -v
Pike v7.6 release 75 Copyright &#9560; 1994-2006 Link&#1046;ping University
Pike comes with ...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4156
Reported by Andrew Shirrayev, <andrews@gate.ort.spb.ru>
```
$ pike7.6 -v
Pike v7.6 release 75 Copyright ╘ 1994-2006 LinkЖping University
Pike comes with ABSOLUTELY NO WARRANTY; This is free software and you are
welcome to redistribute it under certain conditions; Read the files
COPYING and COPYRIGHT in the Pike distribution for more details.
```
Code sample with problem.
```
class test {
object(test) `/(string str)
{
write("DIV : "+str+"\n");
return this_object();
};
object(test) `+(string str)
{
write("ADD : "+str+"\n");
return this_object();
};
object(test) `<<(string str)
{
write("LEFT:"+str+"\n");
return this_object();
};
}
int main(int argc, array argv)
{
object(test) foo=(test()/"qqq")+"zzz";
// ^^ line w/o problem
object(test) foo1=(test()/"qqq")<<"zzz";
// bug.pike:25:Bad argument 2 to `<<.
// bug.pike:25:Expected: !function(!object ... : mixed) & (function(mixed,
// object : mixed) | function(object, mixed : mixed)) | function(int, int :
// int)
// bug.pike:25:Got : function(mixed | void, string : void | mixed)
// Pike: Failed to compile script:
// Compilation failed.
}
```Pike 7.6Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4434Problem with map type (?)2020-03-01T15:02:31ZPeter BortasProblem with map type (?)Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4434
Reported by Martin Nilsson, IDA <nilsson@pike.ida.liu.se>
This code
```
#pragma strict_types
```
string f(int i) { return (string)i; }
```
void main(int n, array(...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4434
Reported by Martin Nilsson, IDA <nilsson@pike.ida.liu.se>
This code
```
#pragma strict_types
```
string f(int i) { return (string)i; }
```
void main(int n, array(string) args)
{
array(int) a = (array(int))(args[0]);
sprintf("%@s", map(a, f));
}
```
produces the warning
```
/home/nilsson/Pike/7.7/type.pike:9: Warning: Type mismatch in argument 2 to
sprintf.
/home/nilsson/Pike/7.7/type.pike:9: Warning: Expected: array(object | string)
/home/nilsson/Pike/7.7/type.pike:9: Warning: Got : array(string | mixed)
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4577switch() on types not working even when `==() succeeds2020-03-01T15:06:56ZPeter Bortasswitch() on types not working even when `==() succeedsImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4577
Reported by Jonas Wallden <jonasw@roxen.com>
```
class Abstract { };
class Fruit { inherit Abstract; };
class Color { inherit Abstract; };
void main()
{
Fruit ban...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4577
Reported by Jonas Wallden <jonasw@roxen.com>
```
class Abstract { };
class Fruit { inherit Abstract; };
class Color { inherit Abstract; };
void main()
{
Fruit banana = Fruit();
Color yellow = Color();
werror("Is banana a fruit? %O\n", object_program(banana) == Fruit);
werror("Is yellow a fruit? %O\n", object_program(yellow) == Fruit);
switch (object_program(banana)) {
case Fruit:
werror("Yes, banana is still a fruit.\n");
break;
default:
werror("Banana is a... uh, don't remember.\n");
break;
}
}
```
Interestingly enough the program works if the inherit of Abstract is removed from the Fruit class.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4793Workaround needed for silent kill() failure in OS X2020-03-01T15:10:00ZPeter BortasWorkaround needed for silent kill() failure in OS XImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4793
Reported by Jonas Wallden <jonasw@roxen.com>
Test 349 from modules/testsuite seems to hang intermittently on OS X. A distilled test case:
class Fnord {
```
int g...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4793
Reported by Jonas Wallden <jonasw@roxen.com>
Test 349 from modules/testsuite seems to hang intermittently on OS X. A distilled test case:
class Fnord {
```
int gnapp(int t)
{
int e;
werror("#%d: STARTING\n", t);
for (e = 0; e < 7; e++) {
for (int d = 0; d < 150; d++) {
object o = Process.create_process( ({ "/bin/sleep", "99999" }) );
int err = kill(o->pid(), 9);
o->wait();
}
}
werror("#%d: DONE\n", t);
return -1;
}
array start()
{
array a = ({ });
for (int e = 0; e < 10; e++)
a += ({ thread_create(gnapp, e) });
return a;
}
};
void main()
{
werror("starting...\n");
array res = Fnord()->start()->wait() - ({ -1 });
werror("res: %O\n", res);
}
```
With tracing enabled in signal_handler.c we've determined that the kill() call in f_kill() returns without error but doesn't terminate the targeted process. The problem has yet to be reduced to a standalone C program, but one hypothesis is that the forked /bin/sleep has not yet started completely before the SIGKILL signal is delivered and that the OS X kernel therefore disregards the signal.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4826New tds module does not handle bindings2020-03-01T15:11:04ZPeter BortasNew tds module does not handle bindingsImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4826
Reported by Marcus Wellhardh <wellhard@roxen.com>
The new tds database module does not work with bindings.
Code, using "tds://test:test@burns/sparq" as connect stri...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4826
Reported by Marcus Wellhardh <wellhard@roxen.com>
The new tds database module does not work with bindings.
Code, using "tds://test:test@burns/sparq" as connect string:
```
void test_char(Sql.Sql db)
{
catch {
db->query("DROP TABLE dbtest");
};
db->query("CREATE TABLE dbtest ("
" ID INT, "
" MY_CHAR CHAR(32) "
")");
db->query("INSERT INTO dbtest (ID, MY_CHAR) VALUES "
"(1, %s)", "abcdefghijklmnopqrstuvxyz");
}
```
Backtrace:
```
15: :BURNS:1 Line 1: Incorrect syntax near ':'.
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/tds.pike:186:
Sql.tds()->tds_error("15: :BURNS:1 Line 1: Incorrect syntax near ':'.\n",1
5,"","BURNS",1,"Line 1: Incorrect syntax near ':'.")
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/tds.pike:677:
Sql.tds()->Connection()->process_msg(Sql.tds()->Connection()->InPacket(),1
70)
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/tds.pike:921:
Sql.tds()->Connection()->process_default_tokens(@0=Sql.tds()->Connection()
->InPacket(),170)
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/tds.pike:1043:
Sql.tds()->Connection()->process_result_tokens(@0)
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/tds.pike:1674:
Sql.tds()->big_query()->create(Sql.tds()->compile_query())
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/tds.pike:37:
Sql.tds()->big_query()
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/Sql.pike:535:
Sql.Sql()->query("INSERT INTO dbtest (ID, MY_CHAR) VALUES (2, :arg0)","abc
defghijklmnopqrstuvxyz")
/home/wellhard/projects/dbtest/dbtest.pike:78: /main()->test_char(Sql.Sql())
/home/wellhard/projects/dbtest/dbtest.pike:411: /main()->main()
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4860external modules do not build when using pike coming with roxen52020-03-01T15:11:52ZPeter Bortasexternal modules do not build when using pike coming with roxen5Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4860
Reported by Arne Goedeke <roxen@laramies.com>
the source distribution of roxen5 ends up with a pike that has the srcdir argument set in the specs. that srcdir parame...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4860
Reported by Arne Goedeke <roxen@laramies.com>
the source distribution of roxen5 ends up with a pike that has the srcdir argument set in the specs. that srcdir parameter ends up as an argument to configure when trying to build cmods. some sample output:
> /home/el/local/roxen/server-5.0.381/pike/bin/pike -x module --query=specs
([ /* 7 elements */
"CC": "/home/el/local/roxen/server-5.0.381/pike/include/pike/smartlink gcc",
"CFLAGS": " -g -ggdb3 -mtune=i686",
"CPP": "gcc -E",
"CPPFLAGS": " -I/home/el/tmp/roxen-5.0.381-src/pike/src/bundles/include",
"LDFLAGS": " -L/home/el/tmp/roxen-5.0.381-src/pike/src/bundles/lib32 -L/home/el/tmp/roxen-5.0.381-src/pike/src/bundles/lib/32 -L/home/el/tmp/roxen-5.0.381-src/pike/src/bundles/lib/. -L/usr/lib/gcc/i686-pc-linux-gnu/4.1.2 -R/usr/lib/gcc/i686-pc-linux-gnu/4.1.2 -L/usr/i686-pc-linux-gnu/lib",
"LDSHARED": "gcc -shared ",
"configure_args": "'--prefix=/home/el/local/' '--cache-file=../.././config.cache' '--srcdir=/home/el/tmp/roxen-5.0.381-src/pike/src'"
])
when trying to do a pike -x module
> /home/el/local/roxen/server-5.0.381/pike/bin/pike -x module
** Old style module
** Running configure (with extra compat args)
./configure --cache-file=./config.cache --prefix=/home/el/local/ --cache-file=../.././config.cache --srcdir=/home/el/tmp/roxen-5.0.381-src/pike/src
configure: error: cannot find sources (json_mapping.c) in /home/el/tmp/roxen-5.0.381-src/pike/srcPike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4897Overzealous compile time type check2020-03-01T15:12:57ZPeter BortasOverzealous compile time type checkImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4897
Reported by Martin Stjernholm <mast@roxen.com>
Consider the following program:
```
constant c = (["x": (["y": ({1,2,3})])]);
int main()
{
werror ("%O\n", ...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4897
Reported by Martin Stjernholm <mast@roxen.com>
Consider the following program:
```
constant c = (["x": (["y": ({1,2,3})])]);
int main()
{
werror ("%O\n", c["x"] && equal (c["x"]["y"], ({1,2,3})));
}
```
It works and writes out "1". Now, if the constant mapping c is replaced with an empty one, it doesn't even compile:
```
foo.pike:4:Indexing on illegal type.
foo.pike:4:Got : string(0..255).
```
The compiler could perhaps optimize the werror expression to 0, but it should compile it even if the mapping happens to be empty. Probably another problem due to an overspecified implied type for constants.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4934pango items are listed as separate functions2020-03-01T15:13:13ZPeter Bortaspango items are listed as separate functionsImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4934
Reference: http://pike.ida.liu.se/generated/manual/modref/ex/predef_3A_3A/GTK2/Pango.AttrList.html
Reported by yvan vander sanden <yvan@youngmusic.org>
On the pike ...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4934
Reference: http://pike.ida.liu.se/generated/manual/modref/ex/predef_3A_3A/GTK2/Pango.AttrList.html
Reported by yvan vander sanden <yvan@youngmusic.org>
On the pike website (module reference), pango functions are listed as GTK2.Pango.Function.
Example: GTK2.Pango.FontDescription()
in the GTK2 test files that come with the source it's:
```
object font_desc= Pango.FontDescription("monospace 10");
```
(which could be right if GTK2 is imported, but that's not the case)
But both are wrong, since it's actually:
GTK2.PangoFontDescription()
Same goes for all other pango functions/objects/programs. It might be a timesaver for new users like me to have the correct information on this on all places :-)
regards,
yvan vander sandenPike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/5466XML parser doesn't flag errors for <?xml ...?> in wrong places2020-03-01T15:18:36ZPeter BortasXML parser doesn't flag errors for <?xml ...?> in wrong placesImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5466
Reported by Jonas Wallden <jonasw@roxen.com>
When the XML parser encounters a <?xml ...?> directive in unexpected places (i.e. not at the very beginning of the docum...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5466
Reported by Jonas Wallden <jonasw@roxen.com>
When the XML parser encounters a <?xml ...?> directive in unexpected places (i.e. not at the very beginning of the document modulo BOM) it is handled incorrectly:
- It is accepted in violiation of the spec (§2.6, <http://www.w3.org/TR/REC-xml/#sec-pi>).
- The comment in compat_allow_errors() says Pike treats it as a normal PI when using the strictest setting.
- The parser callback is invoked with the "<?xml" type and not the "<?" type, thus flagging is as a real XML header and failing in the misguided intention to identify it as a PI.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/6092forkd: Failed to write spawn request2020-03-01T15:26:05ZPeter Bortasforkd: Failed to write spawn requestImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=6092
Reported by Jonas Wallden <jonasw@roxen.com>
Seen on macos_x86_64:
```
: Failed to write spawn request (-1 != 434).
12:52:27 : Error in VCDir(0:0:[FOO]::...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=6092
Reported by Jonas Wallden <jonasw@roxen.com>
Seen on macos_x86_64:
```
: Failed to write spawn request (-1 != 434).
12:52:27 : Error in VCDir(0:0:[FOO]::/global/data/mf/items/3820)->update_state. Additional info:
8m 7.7s : _statcache = Stat(drwxr-xr-x 204b)
: _state = 0
: _md = 0
: status = 0
: infostat = Stat(-rw-r--r-- 89b)
12:52:27 : pike/lib/modules/Process.pmod:230: Process.Process()->create(({"/scratch/FOO/roxen/server-5.2.40/modules/sitebuilder/bin/cvs","-!","-f","-q","-d:local:/scratch/FOO/FOO.sb/cvsroot","-n","status","-v","__info"}),mapping[5])
8m 7.7s : pike/lib/modules/Process.pmod:112: Process->Process()
: modules/sitebuilder/pike-modules/VC.pmod/CVS.pmod/CVS.pike (rev 1.51):129: /scratch/FOO/roxen/server-5.2.40/modules/sitebuilder/pike-modules/VC.pmod/CVS.pmod/CVS()->command2(0,@0=({"/scratch/FOO/roxen/server-5.2.40/modules/sitebuilder/bin/cvs","-!","-f","-q","-d:local:/scratch/FOO/FOO.sb/cvsroot","-n","status","-v","__info"}),0)
```
(Customer name censored.)Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbström