gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] r1662 - GNUnet/src/applications/sqstore_mysql


From: grothoff
Subject: [GNUnet-SVN] r1662 - GNUnet/src/applications/sqstore_mysql
Date: Sat, 13 Aug 2005 23:35:25 -0700 (PDT)

Author: grothoff
Date: 2005-08-13 23:35:24 -0700 (Sat, 13 Aug 2005)
New Revision: 1662

Modified:
   GNUnet/src/applications/sqstore_mysql/Makefile.am
   GNUnet/src/applications/sqstore_mysql/mysql.c
   GNUnet/src/applications/sqstore_mysql/mysqltest.c
Log:
fix

Modified: GNUnet/src/applications/sqstore_mysql/Makefile.am
===================================================================
--- GNUnet/src/applications/sqstore_mysql/Makefile.am   2005-08-14 06:01:19 UTC 
(rev 1661)
+++ GNUnet/src/applications/sqstore_mysql/Makefile.am   2005-08-14 06:35:24 UTC 
(rev 1662)
@@ -28,6 +28,7 @@
  $(top_builddir)/src/util/libgnunetutil.la \
  -lmysqlclient $(ZLIB_LNK)
 
+EXTRA_DIST = check.conf
 
 mysqltest_SOURCES = \
  mysqltest.c 

Modified: GNUnet/src/applications/sqstore_mysql/mysql.c
===================================================================
--- GNUnet/src/applications/sqstore_mysql/mysql.c       2005-08-14 06:01:19 UTC 
(rev 1661)
+++ GNUnet/src/applications/sqstore_mysql/mysql.c       2005-08-14 06:35:24 UTC 
(rev 1662)
@@ -1094,7 +1094,7 @@
 
   /* find out average row length in bytes */
   mysql_query(dbh->dbf,
-             "SHOW TABLE STATUS FROM gnunet LIKE 'gn070'");
+             "SHOW TABLE STATUS LIKE 'gn070'");
   if (mysql_error(dbh->dbf)[0]) {
     DIE_MYSQL("mysql_query", dbh); /* this MUST not fail... */
     MUTEX_UNLOCK(&dbh->DATABASE_Lock_);
@@ -1104,12 +1104,12 @@
     int rows = mysql_num_fields(sql_res);
     sql_row = mysql_fetch_row(sql_res);
     if (sql_row == NULL) {
-      LOG(LOG_ERROR,
+      LOG(LOG_WARNING,
          _("Query '%s' had no results.\n"),
-         "SHOW TABLE STATUS FROM gnunet LIKE 'gn070'");
-      GNUNET_ASSERT(0); /* not allowed to fail*/
+         "SHOW TABLE STATUS LIKE 'gn070'");
       MUTEX_UNLOCK(&dbh->DATABASE_Lock_);
-      return SYSERR;   /* shouldn't get here */
+      BREAK();
+      return 0;        /* shouldn't get here */
     }
     GNUNET_ASSERT( (dbh->avgLength_ID < rows) &&
                   (dbh->avgLength_ID >= 0) );
@@ -1226,7 +1226,7 @@
   /* Find out which column contains the avg row length field and assume
    * that mysqld always gives it in the same order across calls :) */
   mysql_query(dbh->dbf,
-             "SHOW TABLE STATUS FROM gnunet LIKE 'gn070'");
+             "SHOW TABLE STATUS LIKE 'gn070'");
   if (mysql_error(dbh->dbf)[0]) {
     LOG_MYSQL(LOG_ERROR,
              "mysql_query",

Modified: GNUnet/src/applications/sqstore_mysql/mysqltest.c
===================================================================
--- GNUnet/src/applications/sqstore_mysql/mysqltest.c   2005-08-14 06:01:19 UTC 
(rev 1661)
+++ GNUnet/src/applications/sqstore_mysql/mysqltest.c   2005-08-14 06:35:24 UTC 
(rev 1662)
@@ -234,18 +234,9 @@
   FREENONNULL(setConfigurationString("GNUNETD",
                                     "LOGFILE",
                                     NULL));
-  FREENONNULL(setConfigurationString("GNUNETD",
-                                    "LOGLEVEL",
-                                    "WARNING"));
-  FREENONNULL(setConfigurationString("GNUNETD",
-                                    "GNUNETD_HOME",
-                                    "/tmp/gnunet_test/"));
   FREENONNULL(setConfigurationString("FILES",
                                     "gnunet.conf",
-                                    "/tmp/gnunet_test/gnunet.conf"));
-  FREENONNULL(setConfigurationString("MYSQL",
-                                    "DATABASE",
-                                    "gnunetcheck"));
+                                    "check.conf"));
   return OK;
 }
 





reply via email to

[Prev in Thread] Current Thread [Next in Thread]