List:General Discussion« Previous MessageNext Message »
From:wangxu Date:August 1 2007 10:07am
Subject:"segment fault" when using mysql++
View as plain text  
below is my code;these code works very fine until, the length of the 
field "content"  exceeds 300000,
then  "segment fault" happened.
how can I avoid this?

                mysqlpp::Query query = conn.query();
                query << "select content from pages where id="<<id;
                mysqlpp::ResUse res = query.use();
                if (!res) {
                        std::cerr << "Result set is empty!" << std::endl;
                        return 1;
                }
                mysqlpp::Row r;
                while (r = res.fetch_row()) {
                        printf (r["content"]);
              }
Thread
"segment fault" when using mysql++wangxu1 Aug
  • Re: "segment fault" when using mysql++Warren Young2 Aug
    • Re: "segment fault" when using mysql++wangxu2 Aug
      • Re: "segment fault" when using mysql++Pete Harlan3 Aug
        • Re: "segment fault" when using mysql++Michael Dykman3 Aug
      • Re: "segment fault" when using mysql++Warren Young3 Aug