AppWeb Forum

Support for the AppWeb HTTP Server
It is currently Wed Sep 08, 2010 4:55 pm

All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Segmentation error occured when connecting sqlite with php
PostPosted: Sat Jul 17, 2010 8:20 am 
Offline

Joined: Thu Jul 15, 2010 9:01 am
Posts: 2
appweb: 3: @@@ Request =>
GET /con.php HTTP/1.1
Host: 192.168.1.3:8080
User-Agent: Mozilla/5.0 (X11; U; Linux i686; zh-CN; rv:1.9.1.9) Gecko/20100401 9
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: zh-cn,zh;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: GB2312,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Connection: keep-alive

appweb: 4: New request from 192.168.1.1:43553 to :8080
appweb: 2: GET /con.php HTTP/1.1
appweb: 4: Select handler: "phpHandler" for "/con.php"
Segmentation fault

the above is the fault I got. The con.php is as follows:
<html>
<head>
</head>
<body>
<?php
$db = new SQLite3('test.db');
$result = $db->query('SELECT * FROM user');
var_dump($result->fetchArray());
echo "OK";
?>
</body>
</html>

it seemd that when php parser came into $db = new SQLite3('test.db'); , the total appweb will crashed down.
so did it with $db = new PDO('test.db'); and $db = sqlite_open('test.db');
My php is crosscompiled, the configure file is:
'./configure' '--prefix=/home/pbc/web/php-install' '--host=arm-ti-linux' '--disable-debug' '--disable-rpath' '--disable-cli' '--enable-shared' '--enable-static' '--enable-bcmath' '--enable-calendar' '--enable-maintainer-zts' '--enable-embed=shared' '--enable-force-cgi-redirect' '--enable-ftp' '--enable-inline-optimization' '--enable-magic-quotes' '--enable-memory-limit' '--enable-safe-mode' '--enable-sockets' '--enable-track-vars' '--enable-trans-sid' '--enable-mbstring=cn' '--enable-wddx' '--with-pic' '--with-regex=system' '--with-pear' '--with-xml' '--with-xmlrpc' '--enable-pdo' '--with-sqlite' '--with-pdo-sqlite' '--enable-sqlite-utf8' '--with-libxml-dir=../arm-linux-libxml' '--with-zlib-dir=../arm-linux-zlib' '--enable-filter' '--sysconfdir=../php5-arm' '--with-exec-dir=../php5-arm'
I have no idea how to solve this problem ,since google gives me no valid answers.
The official site of php5 said that php5 is set to include sqlite2, but will support sqlite3 with pdo. As can be seen, I've compiled php5 with pdo options. It is such a hard problem that I really can't solve it, so would anybody help me?

Thank you at all for reading this long problem recoding text.


Top
 Profile  
 
 Post subject: Re: Segmentation error occured when connecting sqlite with php
PostPosted: Wed Jul 21, 2010 1:56 am 
Offline

Joined: Wed Nov 19, 2003 11:55 pm
Posts: 481
Does it work with the stock PHP dll/library supplied from PHP.NET?

Peter

_________________
Peter Hale
Gridable Systems


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
[ Time : 0.142s | 10 Queries | GZIP : Off ]