Opened 16 years ago

Closed 16 years ago

#392 closed defect (fixed)

ODBCDriver.lib::odbcdr_rdbi_init() scrambles rdbi_methods on Windows Release x64

Reported by: edzimmerman Owned by: edzimmerman
Priority: major Milestone:
Component: FDO API Version: 3.2.0
Severity: 2 Keywords:
Cc: External ID: 1117781

Description

Consider this test program:

#include <stdio.h> #include <tchar.h> #include "fdo.h"

int _tmain(int argc, _TCHAR* argv[]) {

wchar_t *provider = L"Autodesk.SqlServer.3.3"; printf("%ls\n", provider); wchar_t *connStr = L"Service=TestServer;Username=TestUser;Password=TestPassword";

try {

FdoPtr<IConnectionManager> manager = FdoFeatureAccessManager::GetConnectionManager (); FdoPtr<FdoIConnection> conn = manager->CreateConnection (provider); conn->SetConnectionString(connStr); conn->Open();

FdoPtr<FdoIListDataStores> listDS =( FdoIListDataStores *) conn->CreateCommand(FdoCommandType_ListDataStores);

bool includingNonFDO = false; listDS->SetIncludeNonFdoEnabledDatastores(includingNonFDO);

FdoPtr<FdoIDataStoreReader> dsReader=listDS->Execute(); while(dsReader->ReadNext()) {

printf("%ls\n", dsReader->GetName());

}

} catch (FdoException *ex) {

printf("FdoException: %ls\n", ex->GetExceptionMessage()); ex->Release();

} catch (...) {

printf("Unhandled exception!!!");

}

return 0;

}

If you build this against the Windows Release x64 FDO build and run through the code in the debugger, you will see that it fails due to the function pointers in the method table being initialized is not correct. In the Debug x64 build, the methods table is correct.

Change History (1)

comment:1 by edzimmerman, 16 years ago

Resolution: fixed
Status: newclosed

I eliminated the problem by dropping all the optimization settings from the Windows Release x64 build of ODBCDriver.lib.

Note: See TracTickets for help on using tickets.