Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1XN9Wg-0002Go-4C for pgsql-odbc@arkaria.postgresql.org; Thu, 28 Aug 2014 23:54:46 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1XN9We-0001mP-7H for pgsql-odbc@arkaria.postgresql.org; Thu, 28 Aug 2014 23:54:44 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1XN9Wd-0001mJ-M6 for pgsql-odbc@postgresql.org; Thu, 28 Aug 2014 23:54:43 +0000 Received: from sd.tpf.co.jp ([210.161.239.34]) by magus.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1XN9WX-0007TF-U6 for pgsql-odbc@postgresql.org; Thu, 28 Aug 2014 23:54:42 +0000 Received: (qmail 21194 invoked by uid 502); 28 Aug 2014 23:54:32 -0000 Received: from unknown (HELO ?127.0.0.1?) (100.126.1.62) by sd2.tpf-fw-c.co.jp with SMTP; 28 Aug 2014 23:54:32 -0000 Message-ID: <53FFC137.9030306@tpf.co.jp> Date: Fri, 29 Aug 2014 08:54:31 +0900 From: "Inoue, Hiroshi" User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Jade Koskela CC: pgsql-odbc@postgresql.org Subject: Re: [PATCH] EXC_BAD_ACCESS in SC_execute References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-odbc Precedence: bulk Sender: pgsql-odbc-owner@postgresql.org Hi Jade, (2014/08/27 6:25), Jade Koskela wrote: > Hello, > > I am looking into dmp files which we collect when our application > crashes. Using google breakpad/stackwalking I am generating the > stacktrace. The crash looks like this: > > Crash reason: EXC_BAD_ACCESS / 0x0000000d > Crash address: 0x0 > > Thread 10 (crashed) > 0 psqlodbcw.so!SC_Execute + 0x10bd > > I couldn't get the source line so I had to dig through the assembly. > I was able to determine the error is happening on line statement.c line > 2191 (from the latest version in the repository). Did you build binaries from the latest git? > numcols = QR_NumResultCols(tres); > (this expands to) > numcols = tres->fields->num_fields > > The crash happens on the dereference of fields. It could be a null > pointer, I'm not sure because I can't reproduce the error. > Apparently EXC_BAD_ACCESS can be SIGSEGV or SIGBUS. > I have generated a patch to handle the null pointer case. OK I would check whether fields could be null or not. It would take some time because I don't have much time. regards, Hiroshi Inoue -- I am using the free version of SPAMfighter. SPAMfighter has removed 12430 of my spam emails to date. Get the free SPAMfighter here: http://www.spamfighter.com/len Do you have a slow PC? Try a Free scan http://www.spamfighter.com/SLOW-PCfighter?cid=sigen -- Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-odbc