Ignore:
Timestamp:
Apr 30, 2008, 11:56:45 PM (16 years ago)
Author:
katerina
Message:

Plenty of compiler warnings fixed, SQL query length fixed, doc update.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/testrun_2d.sh

    r51 r170  
    2424CLIENT_BUILDOPTS="--quiet  $TRUST --prefix=$PW_DIR --with-tmp-dir=$PW_DIR --localstatedir=$PW_DIR --enable-network=client --disable-mail --disable-external-scripts --enable-login-watch --enable-xml-log --enable-db-reload --with-logserver=localhost --with-config-file=REQ_FROM_SERVER$PW_DIR/testrc_2 --with-data-file=REQ_FROM_SERVER$PW_DIR/.samhain_file --with-log-file=$PW_DIR/.samhain_log --with-pid-file=$PW_DIR/.samhain_lock"; export CLIENT_BUILDOPTS
    2525
     26create_pgpass () {
     27touch ~/.pgpass
     28chmod 600 ~/.pgpass
     29cat > ~/.pgpass << EOF
     30localhost:*:samhain:samhain:samhain
     31EOF
     32}
     33
    2634check_psql_log () {
    2735    DATE="$1"
    2836
    2937    rm -f test_log_db
    30     PGPASSWORD=samhain; export PGPASSWORD
     38    # PGPASSWORD=samhain; export PGPASSWORD
     39    create_pgpass
    3140    psql -U samhain -d samhain -c "SELECT * FROM log WHERE entry_status = 'NEW' and log_time > '${DATE}';" >test_log_db
    3241    #
     
    7786        return 1
    7887    else
    79         PGPASSWORD="samhain"; export PGPASSWORD
     88        # PGPASSWORD="samhain"; export PGPASSWORD
     89        create_pgpass
    8090        TEST=`psql -U samhain -d samhain -c "SELECT * FROM log LIMIT 1;" 2>/dev/null`
    8191        if [ $? -ne 0 -o -z "$TEST" ]; then
Note: See TracChangeset for help on using the changeset viewer.