sam / do fork watch download tarball
public
Rubygem
Description: DataObjects
Homepage: http://rubyforge.org/projects/dorb
Clone URL: git://github.com/sam/do.git
Search Repo:
Resolves ticket: 
http://wm.lighthouseapp.com/projects/4819/tickets/63-patch-connection-erro
rs-display-sensitive-information#ticket-63-3
sam (author)
Sun Dec 30 07:59:56 -0800 2007
commit  774da22df753b2a85dcb144e15f0a5179a62aa57
tree    83419aa7a47f09d362f4bb61f716277aef02908a
parent  71d359fcef21c5a8583a0ec98d32f76b94005d91
...
32
33
34
35
 
36
37
38
...
32
33
34
 
35
36
37
38
0
@@ -32,7 +32,7 @@ module DataObject
0
         @db = Mysql_c.mysql_init(nil)
0
         raise ConnectionFailed, "could not allocate a MySQL connection" unless @db
0
         conn = Mysql_c.mysql_real_connect(@db, @host, @user, @password, @dbname, @port || 0, @socket, @flags || 0)
0
- raise ConnectionFailed, "The connection with connection string #{@connection_string} failed\n#{Mysql_c.mysql_error(@db)}" unless conn
0
+ raise ConnectionFailed, "Unable to connect to database with provided connection string. \n#{Mysql_c.mysql_error(@db)}" unless conn
0
         @state = STATE_OPEN
0
         true
0
       end
...
18
19
20
21
 
22
23
24
...
18
19
20
 
21
22
23
24
0
@@ -18,7 +18,7 @@ module DataObject
0
       def open
0
         @db = Postgres_c.PQconnectdb(@connection_string)
0
         if Postgres_c.PQstatus(@db) != Postgres_c::CONNECTION_OK
0
- raise ConnectionFailed, "The connection with connection string #{@connection_string} failed\n#{Postgres_c.PQerrorMessage(@db)}"
0
+ raise ConnectionFailed, "Unable to connect to database with provided connection string. \n#{Postgres_c.PQerrorMessage(@db)}"
0
         end
0
         @state = STATE_OPEN
0
         true
...
20
21
22
23
 
24
25
26
...
20
21
22
 
23
24
25
26
0
@@ -20,7 +20,7 @@ module DataObject
0
       def open
0
         r, d = Sqlite3_c.sqlite3_open(@conn)
0
         unless r == Sqlite3_c::SQLITE_OK
0
- raise ConnectionFailed, "The connection with connection string #{@connection_string} failed\n#{Sqlite3_c.sqlite3_errmsg(d)}"
0
+ raise ConnectionFailed, "Unable to connect to database with provided connection string. \n#{Sqlite3_c.sqlite3_errmsg(d)}"
0
         else
0
           @db = d
0
         end

Comments

    No one has commented yet.