Custom Query (1030 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (541 - 543 of 1030)

Ticket Resolution Summary Owner Reporter
#899 fixed segfault in LinuxX8632/WindowsX8632 build using postmodern library R. Matthew Emerson Emit Sorrels
Description

I've reproduced the problem with the binary release (1.7-r14925M) and also a rebuild from svn (1.7-r15146M). There is no such problem when using the 64 bit linux version. I've tested the LinuxX8632 in 32bit linux 2.6.32 (debian squeeze) and also 64bit install 3.0 (arch linux). The postgresql server is version 8.4 (not relevant).

steps to reproduce:

;; install latest postmodern somehow. 
;; I've tried the one from quicklisp dist and 
;; also the latest git version from 
;; http://marijnhaverbeke.nl/postmodern/#download

(ql:quicklisp :postmodern) 
(pomo:connect-toplevel "dbname" "user" "pass" "host")
(pomo:query "select '42'")

expected result: (("42")) <--- ok in sbcl and LinuxX8664 ccl

in LinuxX8632 ccl I get:

> Error: Database error: Unexpected end of file on #<BASIC-TCP-STREAM :CLOSED #x188F5736>
> While executing: (:INTERNAL #:G5027 CL-POSTGRES:EXEC-QUERY), in process listener(1).
> Type :POP to abort, :R for a list of available restarts.
> Type :? for other options.

At first it looks like a bug in the library, but tcpdump reveals mangled data in which the length of simple-describe-message packet is declared incorrectly as 1. This four byte length value in the packet's header is computed through define-message macro in postmodern/cl-postgres/messages.lisp.

During macro expansion it appears to correctly compute, but when it finally gets sent through (simple-describe-message socket) in cl-postgres:send-query, it's accessing some garbage.

Through defmacro integer-writer (postmodern/cl-postgres/communicate.lisp), a bunch of functions called uint1 uint2 uint4 etc are created which send bytes to socket through write-byte. I changed all the occurrences of write-byte in this macro to my-write-byte and defined

(defun my-write-byte (value socket)
  (format t "~a~%" value)
  (write-byte value socket))

I'm not sure if it's relevant but I also commented out all the #.optimize. After intercepting all the write-bytes with my-write-bytes, it dumps the value of each byte sent (for integer fields); when it comes to accessing the length it now dumps the following error

;;; (pomo:query "select '42'")
;; protocol.lisp (send-query ..
80      ; 'P' --- Parse command packet (simple-parse-message ..)
0
0
0
19      ; 19 bytes (length of parse packet)
0
0
;;;;; string select '42' is sent here
0       ; number of param data types (0)
0
68      ; 'D' --- Describe command (simple-describe-message ..)
0
0
0
> Error: Fault during read of memory address #x0
> While executing: CCL::VALID-HEADER-P, in process listener(1).
> Type :POP to abort, :R for a list of available restarts.
> Type :? for other options.
1 > q
;;;; length of message = 1 in 32bit ccl. 6 in sbcl and 64bit ccl

No backtrace is available. Last byte (least significant byte of the length value) should be 6, which tells postgresql that the packet is six bytes: 4 byte length field + 2 bytes of data. If I check the value of the length variable, "base-length", computed during macro expansion of define-message simple-describe-message, it appears correct (=6).

Sending the 0x00000001 as length of the packet naturally causes postgresql to output the following error to syslog: invalid message length and the connection is dropped.

If I repeat with gdb attached to the process I get:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xf740ab70 (LWP 5227)]
0x1040547e in ?? ()
(gdb) bt
#0  0x1040547e in ?? ()
#1  0x10404c65 in ?? ()
#2  0x104400a5 in ?? ()
#3  0x1044749d in ?? ()
#4  0x08054445 in _SPFret1valn () at ../x86-spentry32.s:955
#5  0x100d8d55 in ?? ()
#6  0x08054445 in _SPFret1valn () at ../x86-spentry32.s:955
#7  0x10506c9d in ?? ()
#8  0x10502c25 in ?? ()
#9  0x1086eb75 in ?? ()
#10 0x100899f5 in ?? ()

I'm not certain but I'm inclined to believe this is a bug in ccl.

#901 fixed Search files dialog, uncheck "Search Comments" bug p2
Description

On unchecking the Search files Search Comments check box, I'm thrown to the Altconsole with

Error: Unknown checkbox #<NS-BUTTON <NSButton: 0x1166780> (#x1166780)>

While executing: (:INTERNAL GUI::toggleCheckbox:|), in process Initial(0).

1.8-dev-r15113M-trunk (DarwinX8664)

#905 fixed Apparent race condition in gui:background-process-run-function Gary Byers Ron Garret
Description

This:

(dotimes (i 3) (gui:background-process-run-function "foo" (lambda () (print 123))))

results in one successfully spawned process and one that reports:

Error: "Untitled 2" already exists

(with one of the most horrifically long backtraces I have ever seen from a process that did not actually overflow the stack).

But this:

(dotimes (i 2) (gui:background-process-run-function "foo" (lambda () (print 123))) (sleep 0.01))

results in two successfully spawned processes. These results are repeatable for N>2. My guess is this is a race condition having to do with the naming of the windows that are created by the underlying deferred-cocoa-listener-output-streams but I have not been able to verify this.

Batch Modify
Note: See TracBatchModify for help on using batch modify.
Note: See TracQuery for help on using queries.