pike issueshttps://git.lysator.liu.se/pikelang/pike/-/issues2009-11-10T10:43:42Zhttps://git.lysator.liu.se/pikelang/pike/-/issues/5088MySQL module doesn't link on Windows2009-11-10T10:43:42ZPeter BortasMySQL module doesn't link on WindowsImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5088
Reported by Jonas Wallden <jonasw@roxen.com>
```
make[5]: Entering directory `/export/d1/dist/5.0/build/pike.win32_x86/build/modules/Mysql'
Linking Mysql
Creating...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5088
Reported by Jonas Wallden <jonasw@roxen.com>
```
make[5]: Entering directory `/export/d1/dist/5.0/build/pike.win32_x86/build/modules/Mysql'
Linking Mysql
Creating library module.lib and object module.exp
result.obj : error LNK2019: unresolved external symbol _STRTOL referenced in function _f_fetch_row
module.so : fatal error LNK1120: 1 unresolved externals
CL returned error code 2.
Linking failed:
/export/d1/dist/5.0/build/pike.win32_x86/pike/bin/smartlink /export/d1/dist/5.0/build/pike.win32_x86/pike/bin/smartlink rntcl -shared -g -MD -O2 -DDYNAMIC_MODULE -l/export/d1/dist/5.0/build/pike.win32_x86/build/pike -pdb:Mysql.pdb -o module.so mysql.o result.o -L/export/d1/dist/5.0/build/pike.win32_x86/build/bundles/lib32 -L/export/d1/dist/5.0/build/pike.win32_x86/build/bundles/lib/32 -L/export/d1/dist/5.0/build/pike.win32_x86/build/bundles/lib/. -lshell32 -lkernel32 -lws2_32 -ladvapi32 -llibmysql -lc
make[5]: *** [module.so] Error 1
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/5086Segfault in type resolver2009-11-09T18:18:36ZPeter BortasSegfault in type resolverImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5086
Reported by Martin Stjernholm <mast@roxen.com>
The following minimized program dumps core:
```
class X
{
X bar();
}
class Y
{
constant X = global...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5086
Reported by Martin Stjernholm <mast@roxen.com>
The following minimized program dumps core:
```
class X
{
X bar();
}
class Y
{
constant X = global::X;
X foo();
}
```
Note that both foo and bar declarations have to exist with the type X in them to trig the bug.
In 7.6 there's instead a compilation error "Constant values may not have references to this" on the constant definition line.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/5085Segfault in mapping iterator2009-11-09T17:45:55ZPeter BortasSegfault in mapping iteratorImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5085
Reported by Martin Stjernholm <mast@roxen.com>
This dumps:
```
get_iterator(([1:1]))->_random();
```
Works in 7.6.Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5085
Reported by Martin Stjernholm <mast@roxen.com>
This dumps:
```
get_iterator(([1:1]))->_random();
```
Works in 7.6.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/5060SQL-typade kolumner, strängar i PIKE2009-11-24T10:35:41ZPeter BortasSQL-typade kolumner, strängar i PIKEImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5060
Reported by Henrik Stadler, Roxen <henrik.stadler@roxen.com>
Nytt API i Pike med castade strängar.Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=5060
Reported by Henrik Stadler, Roxen <henrik.stadler@roxen.com>
Nytt API i Pike med castade strängar.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/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/4868Sporadic crashes in opcode_F_ARROW2015-03-30T18:01:32ZPeter BortasSporadic crashes in opcode_F_ARROWImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4868
Reported by Jonas Wallden <jonasw@roxen.com>
This is a Pike on OS X/PPC problem that's been observed repeatedly over a long period of time in 7.8. It's happening dur...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4868
Reported by Jonas Wallden <jonasw@roxen.com>
This is a Pike on OS X/PPC problem that's been observed repeatedly over a long period of time in 7.8. It's happening during startup of Roxen CMS and normally disappears on next restart.
Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x0000001e
```
Thread 0 Crashed:
0 <<00000000>> 0x03000df8 0 + 50335224
1 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
2 roxen 0x000dd05c object_index_no_free + 320 (object.c:1374)
3 roxen 0x00016368 opcode_F_ARROW + 104 (interpret_functions.h:1842)
4 <<00000000>> 0x03001a30 0 + 50338352
5 roxen 0x0001f860 apply_low_safe_and_stupid + 820 (interpret.c:2404)
6 roxen 0x0014e19c eval_low + 256 (las.c:5270)
7 roxen 0x00157fd8 optimize + 1956 (las.c:1988)
8 roxen 0x0015ed6c dooptcode + 132 (las.c:5196)
9 roxen 0x00005f6c yyparse + 9396 (language.yacc:1087)
10 roxen 0x001047dc run_pass2 + 736 (program.c:3628)
11 roxen 0x00106490 f_compilation_compile + 824 (program.c:8563)
12 roxen 0x0001b2f8 low_mega_apply + 2244 (apply_low.h:388)
13 roxen 0x0001c5c4 mega_apply + 168 (interpret.c:2211)
14 roxen 0x000eff2c f_compilation_env_compile + 124 (program.c:7677)
15 roxen 0x0001b2f8 low_mega_apply + 2244 (apply_low.h:388)
16 roxen 0x0001c5c4 mega_apply + 168 (interpret.c:2211)
17 <<00000000>> 0x01297c2c 0 + 19495980
18 roxen 0x000186f0 catching_eval_instruction + 160 (interpret.c:2246)
19 roxen 0x0001fb5c jump_opcode_F_CATCH + 412 (interpret_functions.h:1287)
20 <<00000000>> 0x007fe6bc 0 + 8382140
21 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
22 roxen 0x0014743c svalue_is_true + 308 (svalue.c:550)
23 roxen 0x00013c50 test_opcode_F_BRANCH_WHEN_ZERO + 96 (interpret_functions.h:1118)
24 <<00000000>> 0x010ea894 0 + 17737876
25 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
26 roxen 0x000dd05c object_index_no_free + 320 (object.c:1374)
27 <<00000000>> 0x010ed240 0 + 17748544
28 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
29 roxen 0x000dd05c object_index_no_free + 320 (object.c:1374)
30 roxen 0x000ebdf4 f_index + 132 (operators.c:181)
31 roxen 0x00154628 index_node + 1204 (las.c:1672)
32 roxen 0x0000c548 yyparse + 35472 (language.yacc:3897)
33 roxen 0x00105e84 run_pass1 + 912 (program.c:8030)
34 roxen 0x00106404 f_compilation_compile + 684 (program.c:8542)
35 roxen 0x0001b2f8 low_mega_apply + 2244 (apply_low.h:388)
36 roxen 0x0001c5c4 mega_apply + 168 (interpret.c:2211)
37 roxen 0x000eff2c f_compilation_env_compile + 124 (program.c:7677)
38 roxen 0x0001b2f8 low_mega_apply + 2244 (apply_low.h:388)
39 roxen 0x0001c5c4 mega_apply + 168 (interpret.c:2211)
40 <<00000000>> 0x01299658 0 + 19502680
41 roxen 0x000186f0 catching_eval_instruction + 160 (interpret.c:2246)
42 roxen 0x0001fb5c jump_opcode_F_CATCH + 412 (interpret_functions.h:1287)
43 <<00000000>> 0x021d7f00 0 + 35487488
44 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
45 roxen 0x000e6f90 o_cast + 2148 (operators.c:687)
46 roxen 0x000e7ac4 f_cast + 72 (operators.c:913)
47 <<00000000>> 0x02a39628 0 + 44275240
48 roxen 0x000186f0 catching_eval_instruction + 160 (interpret.c:2246)
49 roxen 0x0001fb5c jump_opcode_F_CATCH + 412 (interpret_functions.h:1287)
50 <<00000000>> 0x021bd72c 0 + 35378988
51 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
52 roxen 0x00053e8c backend_do_call_outs + 1024 (backend.cmod:876)
53 roxen 0x00055ee0 f_PollDeviceBackend_cq__backtick_28_29 + 1780 (backend.cmod:3406)
54 roxen 0x0001b2f8 low_mega_apply + 2244 (apply_low.h:388)
55 roxen 0x0001edb4 jump_opcode_F_CALL_FUNCTION_AND_POP + 100 (interpret_functions.h:2068)
56 <<00000000>> 0x012ab138 0 + 19575096
57 roxen 0x000186f0 catching_eval_instruction + 160 (interpret.c:2246)
58 roxen 0x0001fb5c jump_opcode_F_CATCH + 412 (interpret_functions.h:1287)
59 <<00000000>> 0x012a9d90 0 + 19570064
60 roxen 0x0001c5dc mega_apply + 192 (interpret.c:2218)
61 roxen 0x00002d04 main + 3096 (main.c:621)
62 roxen 0x00001d0c _start + 760
63 roxen 0x00001a10 start + 48
```
Thread 0 crashed with PPC Thread State 64:
srr0: 0x0000000003000df8 srr1: 0x100000000200f030 vrsave: 0x0000000000000000
cr: 0x42008444 xer: 0x0000000000000000 lr: 0x000000000000f3d0 ctr: 0x0000000003000df4
r0: 0x000000000001c5dc r1: 0x00000000bfff6df0 r2: 0x0000000000294660 r3: 0x0000000003000df4
r4: 0x00000000000000dc r5: 0x00000000000186a0 r6: 0x0000000000000006 r7: 0x0000000000000000
r8: 0x0000000000294660 r9: 0x0000000000294660 r10: 0x0000000000000013 r11: 0x000000000000000a
r12: 0x0000000000000012 r13: 0x000000000000011a r14: 0x0000000000000000 r15: 0x0000000000294660
r16: 0x00000000002ace14 r17: 0x0000000000000018 r18: 0x00000000ffffffff r19: 0x0000000001817ed0
r20: 0x0000000000000000 r21: 0x0000000000000000 r22: 0x0000000000000449 r23: 0x0000000001e0add8
r24: 0x0000000000000008 r25: 0x0000000000000000 r26: 0x0000000000000016 r27: 0x0000000001d8c9d8
r28: 0x00000000bfff6f50 r29: 0x0000000000294660 r30: 0x0000000003000df4 r31: 0x000000000000f3d0
The corresponding startup log for Roxen says:
Enabling all modules for Test Platform...
Start script terminating.
For historical reference, this is the crash I caught back in Sept 2008 (from InfoKOM 629415). The topmost stack frames are a bit different but opcode_F_ARROW and below is more or less identical:
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000048bbc606
Crashed Thread: 0
```
Thread 0 Crashed:
0 ??? 0x023fb9d8 0 + 37730776
1 pike 0x00016a6c opcode_F_ARROW + 100 (interpret_functions.h:1843)
2 pike 0x0001f8f4 apply_low_safe_and_stupid + 816 (interpret.c:2391)
3 pike 0x0014ac54 eval_low + 252 (las.c:5270)
4 pike 0x00154ac0 optimize + 1976 (las.c:1989)
5 pike 0x0015b84c dooptcode + 128 (las.c:5196)
6 pike 0x000068e8 yyparse + 9408 (language.yacc:1080)
7 pike 0x00101a40 run_pass2 + 732 (program.c:8011)
8 pike 0x001036f4 f_compilation_compile + 820 (program.c:8474)
9 pike 0x0001b494 low_mega_apply + 2104 (apply_low.h:225)
10 pike 0x0001c67c mega_apply + 164 (interpret.c:2201)
11 pike 0x000ed3d8 f_compilation_env_compile + 120 (program.c:7589)
12 pike 0x0001b494 low_mega_apply + 2104 (apply_low.h:225)
13 pike 0x0001c67c mega_apply + 164 (interpret.c:2201)
14 ??? 0x0067cc28 0 + 6802472
15 pike 0x00018a20 catching_eval_instruction + 96 (interpret.c:2233)
16 pike 0x0001fc20 jump_opcode_F_CATCH + 456 (interpret_functions.h:1287)
[...]
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4867-x monger --install does not work when started with a relative path2009-06-24T22:40:07ZPeter Bortas-x monger --install does not work when started with a relative pathImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4867
Reported by Arne Goedeke <roxen@laramies.com>
this happens when starting the pike binary using a relative path, e.g. doing ./pike/bin/pike inside a roxen installatio...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4867
Reported by Arne Goedeke <roxen@laramies.com>
this happens when starting the pike binary using a relative path, e.g. doing ./pike/bin/pike inside a roxen installation. The monger module uses master()->pike_file_name after changing the current working directory. If pike_file_name is a relative path the binary cannot be found after cd().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/4855"Bad offset" when generating backtrace2009-06-17T17:42:07ZPeter Bortas"Bad offset" when generating backtraceImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4855
Reported by Jonas Wallden <jonasw@roxen.com>
```
class Abstract {
void foo();
}
void main()
{
Abstract()->foo();
}
ceylon:~ $ ~/pike/7.8/bin/pike ~/bad-offset...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4855
Reported by Jonas Wallden <jonasw@roxen.com>
```
class Abstract {
void foo();
}
void main()
{
Abstract()->foo();
}
ceylon:~ $ ~/pike/7.8/bin/pike ~/bad-offset.pike
Bad offset: pc:0x6d2194 program:0x6d2198 (0x0)
Calling undefined function.
/main()->Abstract: /main()->Abstract()->foo()
bad-offset.pike:7: /main()->main()
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4851utime on a directory fails2015-03-27T17:43:33ZPeter Bortasutime on a directory failsImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4851
Reported by Tor Edvardsson <tor@roxen.com>
On Windows, utime on a directory gives the following
```
Pike v7.8 release 286 running Hilfe v3.5 (Incremental Pike Fron...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4851
Reported by Tor Edvardsson <tor@roxen.com>
On Windows, utime on a directory gives the following
```
Pike v7.8 release 286 running Hilfe v3.5 (Incremental Pike Frontend)
> object o = file_stat("test");
> utime("test", o->atime, o->mtime);
Compiler Warning: 1: Returning a void expression. Converted to zero.
utime(): Failed: Access denied
HilfeInput:1: HilfeInput()->___HilfeWrapper()
```
on a normal file this works
```
Pike v7.8 release 286 running Hilfe v3.5 (Incremental Pike Frontend)
> object o = file_stat("test.txt");
> utime("test.txt", o->atime, o->mtime);
Compiler Warning: 1: Returning a void expression. Converted to zero.
(1) Result: 0
```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/4818Timestamp gives backtrace in oracle module2009-05-19T16:07:04ZPeter BortasTimestamp gives backtrace in oracle moduleImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4818
Reported by Marcus Wellhardh <wellhard@roxen.com>
The timestamp datatype in the oracle module does not work.
The following code:
```
void test_timestamp(Sql.Sql db...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4818
Reported by Marcus Wellhardh <wellhard@roxen.com>
The timestamp datatype in the oracle module does not work.
The following code:
```
void test_timestamp(Sql.Sql db)
{
catch {
db->query("DROP TABLE dbtest");
};
db->query("CREATE TABLE dbtest ("
" id NUMBER, "
" my_varchar2 VARCHAR2(255), "
" my_timestamp TIMESTAMP"
")");
array(mapping) res =
db->query("SELECT * "
"FROM dbtest");
}
void main()
{
Sql.Sql db = Sql.Sql("oracle://scott:tiger@SNIGEL");
test_timestamp(db);
}
```
Gives the following backtrace:
```
OCIStmtFetch:code=-1:ORA-00932: inconsistent datatypes: expected BINARY got TIMESTAMP
src/modules/Oracle/oracle.c:2591:
Sql.oracle()->compile_query()->big_typed_query()->fetch_row()
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Oracle.pmod:65:
Sql.oracle()->big_query()->fetch_row()
/tmp/dbtest/roxen/server-5.0.352/pike/lib/pike/modules/Sql.pmod/Sql.pike:372:
Sql.Sql()->res_obj_to_array(Sql.oracle()->big_query())
/home/wellhard/projects/dbtest/dbtest.pike:26:
/main()->test_timestamp(Sql.Sql())
/home/wellhard/projects/dbtest/dbtest.pike:77: /main()->main()
```
Tested with roxen-5.0.352-test-cms-rhel5_x86.sh on lemmings.roxen.comPike 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/4773Protocols.HTTP.Query doesn't always remove timeout callback properly2009-06-22T12:40:53ZPeter BortasProtocols.HTTP.Query doesn't always remove timeout callback properlyImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4773
Reported by Tobias Liin <liin@roxen.com>
When using Protocols.HTTP.Query()->timed_async_fetch() both the ok callback
and the fail callback will be called, after a su...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4773
Reported by Tobias Liin <liin@roxen.com>
When using Protocols.HTTP.Query()->timed_async_fetch() both the ok callback
and the fail callback will be called, after a successful fetch.
```
### example: ###
object o;
int main() {
o = Protocols.HTTP.Query();
o->data_timeout = 4;
o->set_callbacks(req_ok, req_fail);
o->async_request("www.roxen.com", 80, "GET /index.xml HTTP/1.0");
return -1;
}
void req_ok() {
werror("req_ok(): %O\n", o);
o->timed_async_fetch(data_ok, data_fail);
}
void req_fail() {
werror("req_fail: %O()\n", o);
}
void data_ok() {
werror("data_ok: %O()\n", o);
}
void data_fail() {
werror("data_fail: %O()\n", o);
}
###############
```
The following patch for Query.pike v1.101 will fix it (I don't know if its
the best way though):
```
@@ -376,6 +376,7 @@
if (!zero_type (headers["content-length"]) &&
sizeof(buf)-datapos>=(int)headers["content-length"])
{
+ remove_call_out(async_timeout);
con->set_nonblocking(0,0,0);
request_ok(@extra_args);
}
```
It adds remove_call_out(async_timeout); in async_fetch_read() in the case
of all data having been received.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4684Hilfe weirdness2009-11-17T17:52:30ZPeter BortasHilfe weirdnessImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4684
Reported by Jonas Wallden <jonasw@roxen.com>
```
Pike v7.8 release 146 running Hilfe v3.5 (Incremental Pike Frontend)
> mapping m = ([ 1 : "one", 2 : "two", 3 : "thr...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4684
Reported by Jonas Wallden <jonasw@roxen.com>
```
Pike v7.8 release 146 running Hilfe v3.5 (Incremental Pike Frontend)
> mapping m = ([ 1 : "one", 2 : "two", 3 : "three" ]);
> m & ({ 3 });
Compiler Error: 1: syntax error, unexpected '&'
Compiler Error: 1: Missing ';'.
Compiler Error: 2: syntax error, unexpected '&'
> (m) & ({ 3 });
(1) Result: ([ /* 1 element */
3: "three"
])
>
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4651pass variable contains null character to postgres may cause SQL error2009-04-16T14:11:39ZPeter Bortaspass variable contains null character to postgres may cause SQL errorImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4651
Reported by Eiichiro ITANI, <emu@ceres.dti.ne.jp>
I'm not sure this is bug, or wrong usage of tag.
It cause SQL error to throw query postgres with array variable.
S...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4651
Reported by Eiichiro ITANI, <emu@ceres.dti.ne.jp>
I'm not sure this is bug, or wrong usage of tag.
It cause SQL error to throw query postgres with array variable.
Suppose test.html contains these lines.
```
<emit source="sql" host="postgres-server"
query="SELECT :v AS v" bindings="v=form.v">
&_.v;
</emit>
```
Then, accessing
http://host/test.html?v=1&v=2
causes error
RXML run error: Query failed: ERROR: unterminated quoted string at or near
"'1"
LINE 1: SELECT '1
^
| <emit bindings="v=form.v" host="postgres-server" query="SELECT :v as v"
source="sql">
That error happened because null character directry passed to postgres server.
Of course, I should check and sanitize form.v to be plain string.
And I also noticed, accessing
http://host/test.html?v=abc%00def
this would make reply just "abc". I checked query log of postgres, and
found that query
as follows:
BEGIN
DECLARE _pikecursor CURSOR FOR SELECT 'abc' as v
FETCH 64 IN _pikecursor
FETCH 64 IN _pikecursor
COMMIT
Characters after null chopped.
Aren't they quoting problem of postgresql binding?Pike 7.4Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4632Locale problems while building Pike2009-04-16T14:11:39ZPeter BortasLocale problems while building PikeImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4632
Reported by @zino
A Polish developer runs who ran "make" got this output:
```
Compiling tmodule.c
sed -e 's![^ -~]lib_prefix[^ -~]!/home/opera/instalki/pike-current...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4632
Reported by @zino
A Polish developer runs who ran "make" got this output:
```
Compiling tmodule.c
sed -e 's![^ -~]lib_prefix[^ -~]!/home/opera/instalki/pike-current/build/
linux-2.6.27-7-generic-x86_64/lib!' -e 's![^ -~]share_prefix[^ -~]!/home/
opera/instalki/pike-current/lib!' -e 's![^ -~]include_prefix[^ -~]!/home/
opera/instalki/pike-current/build/linux-2.6.27-7-generic-x86_64/bundles/
include/pike!' -e 's,x,x,' </home/opera/instalki/pike-current/lib/
master.pike.in >master.pike
sed: -e expression #1, char 99: Invalid range end
make[2]: *** [master.pike] Error 1
make[1]: *** [_make_in_builddir] Error 2
make: *** [compile] Error 2
```
With the following environment:
Ununtu
sed 4.1.5
make 3.61
tcsh 6.14.00-7ubutu1
LANG=pl_PL.UTF-8
LC_MESSAGES=C
The following patch from Piotr Smyrak fixes it, but I'm unsure about the
implications for legacy systems:
```
--- src/Makefile.in.orig 2008-11-07 15:26:57.000000000 +0100
+++ src/Makefile.in 2008-11-07 15:27:50.000000000 +0100
@@ -924,7 +924,7 @@
then u=s,x,x,; \
else u='s/^#undef PIKE_MODULE_RELOC/#define PIKE_MODULE_RELOC
1/'; \
fi; \
- LC_CTYPE=C; LC_LANG=C; export LC_CTYPE LC_LANG;
+ LC_CTYPE=C; LC_COLLATE=C; export LC_CTYPE LC_COLLATE; \
cmd="sed -e 's![^ -~]lib_prefix[^ -~]!`echo '$(TMP_LIBDIR)' | ./
posix_to_native.sh`!' \
-e 's![^ -~]share_prefix[^ -~]!`echo '$(LIBDIR_SRC)' | ./
posix_to_native.sh`!' \
-e 's![^ -~]include_prefix[^ -~]!`echo '$(TMP_BUILDDIR)/bundles/
include/pike' | ./posix_to_native.sh`!' \
```Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4605Comparing NaN with bignums yields FPE2009-11-17T19:08:26ZPeter BortasComparing NaN with bignums yields FPEImported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4605
Reported by Martin Karlgren <marty@roxen.com>
```
Pike v7.4 release 528 running Hilfe v3.5 (Incremental Pike Frontend)
> float kNAN = sscanf("\x7f\xf8\0\0\0\0\0\0", ...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4605
Reported by Martin Karlgren <marty@roxen.com>
```
Pike v7.4 release 528 running Hilfe v3.5 (Incremental Pike Frontend)
> float kNAN = sscanf("\x7f\xf8\0\0\0\0\0\0", "%8F", float _NAN) && _NAN;
> pow(2, 32) > kNAN;
Floating point exception
```
$ uname -a
Darwin gabrielle.roxen.com 9.3.0 Darwin Kernel Version 9.3.0: Fri May 23
00:49:16 PDT 2008; root:xnu-1228.5.18~1/RELEASE_I386 i386Pike 7.4Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbströmhttps://git.lysator.liu.se/pikelang/pike/-/issues/4579Hyperactive Directory Administrator does not work in 7.82009-04-16T14:11:39ZPeter BortasHyperactive Directory Administrator does not work in 7.8Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4579
Reported by @zino
Bills Hyperactive Directory Administrator (http://hww3.riverweb.com/
hdadmin/#download) that hasn't been updated since 2002 does not work with
7.8,...Imported from http://bugzilla.roxen.com/bugzilla/show_bug.cgi?id=4579
Reported by @zino
Bills Hyperactive Directory Administrator (http://hww3.riverweb.com/
hdadmin/#download) that hasn't been updated since 2002 does not work with
7.8, or 7.6 for that matter. The web page states it's been tested with
7.4.20, but even trying to run it in compatibility mode gives the same
resolver problem:
```
% ~/bin/pike77/bin/pike -M. -V 7.4.20 hdadmin.pike
util.pike:33:Trying to inherit placeholder program (resolver problem).
hdadmin.pike:31:Error finding program
hdadmin.pike:31:Illegal program pointer.
```
Granted, it will probably fail due to lack of GTK on all modern systems,
but that is another problem.
Caveat emptor: The 7.7 I'm using is slightly old and I haven't tried with
7.4. Just jotting it down for future study.Pike 7.8Henrik (Grubba) GrubbströmHenrik (Grubba) Grubbström