Connection Exception
--------------------

                 Key: DNET-572
                 URL: http://tracker.firebirdsql.org/browse/DNET-572
             Project: .NET Data provider
          Issue Type: Bug
          Components: ADO.NET Provider
    Affects Versions: 4.5.1.0
            Reporter: Alex Phoenix
            Assignee: Jiri Cincura


Hi, guys. I think, it's time to resolve bug that described here:
http://stackoverflow.com/questions/1806144/firebird-connection-error-after-converting-project-from-vs2005-to-vs2008

I had exception while trying connect to Firebird:

System.ArgumentOutOfRangeException: Index was out of range. Must be 
non-negative and less than the size of the collection.
Parameter name: index.
   в System.Collections.ArrayList.get_Item(Int32 index)
   в FirebirdSql.Data.Client.Managed.Version10.GdsDatabase.GetServerVersion() в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\Client\Managed\Version10\GdsDatabase.cs:строка
 611
   в FirebirdSql.Data.Client.Managed.Version10.GdsDatabase.AfterAttachActions() 
в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\Client\Managed\Version10\GdsDatabase.cs:строка
 242
   в 
FirebirdSql.Data.Client.Managed.Version10.GdsDatabase.Attach(DatabaseParameterBuffer
 dpb, String dataSource, Int32 port, String database) в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\Client\Managed\Version10\GdsDatabase.cs:строка
 220
   в FirebirdSql.Data.FirebirdClient.FbConnectionInternal.Connect() в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\FirebirdClient\FbConnectionInternal.cs:строка
 191
   в 
FirebirdSql.Data.FirebirdClient.FbConnectionPoolManager.Pool.CreateNewConnection(FbConnectionString
 connectionString, FbConnection owner) в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\FirebirdClient\FbConnectionPoolManager.cs:строка
 162
   в 
FirebirdSql.Data.FirebirdClient.FbConnectionPoolManager.Pool.CreateNewConnectionIfPossibleImpl(FbConnectionString
 connectionString, FbConnection owner) в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\FirebirdClient\FbConnectionPoolManager.cs:строка
 191
   в 
FirebirdSql.Data.FirebirdClient.FbConnectionPoolManager.Pool.GetConnection(FbConnection
 owner) в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\FirebirdClient\FbConnectionPoolManager.cs:строка
 106
   в 
FirebirdSql.Data.FirebirdClient.FbConnectionPoolManager.Get(FbConnectionString 
connectionString, FbConnection owner) в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\FirebirdClient\FbConnectionPoolManager.cs:строка
 210
   в FirebirdSql.Data.FirebirdClient.FbConnection.Open() в 
c:\Users\Jiri\Documents\devel\NETProvider\working\NETProvider\src\FirebirdSql.Data.FirebirdClient\FirebirdClient\FbConnection.cs:строка
 539


Replacing line return 
this.GetDatabaseInfo(items, IscCodes.BUFFER_SIZE_256)[0].ToString(); 

to this 

ArrayList ar = this.GetDatabaseInfo(items, IscCodes.BUFFER_SIZE_256);
            if (ar.Count > 0)
                return ar[0].ToString();
            else
                return String.Empty;

helped me

File version: FirebirdSql.Data.FirebirdClient.dll       4.5.1.0

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://tracker.firebirdsql.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
_______________________________________________
Firebird-net-provider mailing list
Firebird-net-provider@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider

Reply via email to