home clear 64x64
en blue 200x116 de orange 200x116 info letter User
suche 36x36
Latest versionsfixlist
11.1.0.7 FixList
10.5.0.9 FixList
10.1.0.6 FixList
9.8.0.5 FixList
9.7.0.11 FixList
9.5.0.10 FixList
9.1.0.12 FixList
Have problems? - contact us.
Register for free anmeldung-x26
Contact form kontakt-x26

DB2 - Problem description

Problem IC74031 Status: Closed

REUSING OF DB2HISTORYDATA STRUCTURE FOR REPEATED DB2HISTORYGETENTRY API
CALLS MIGHT PRODUCE UNEXPECTED RESULTS

product:
DB2 FOR LUW / DB2FORLUW / 970 - DB2
Problem description:
db2HistoryGetEntry has a field pioHistData which takes in a 
struct of db2HistoryData type.  If an application reuses the 
same db2HistoryData type for consecutive calls to 
db2HistoryGetEntry, then the API might produce wrong results, or 
even trap. 
 
The problem has to do with a field inside the db2HistoryData 
called poEventSQLCA.  If this field is unset, then internally 
the db2HistoryGetEntry API will set it up with a dummy for the 
API to process.  At the end of the API it will free the memory 
of the dummy but not nullify the pointer on the structure.  This 
causes problem to subsequent calls to db2HistoryGetEntry with 
the same instance of db2HistoryData struct as the pointer is 
non-NULL and the API tries to dereference it. 
 
This problem only happens when using a v97 client to talk to a 
server in v97 or above.
Problem Summary:
**************************************************************** 
* USERS AFFECTED:                                              * 
* user of db2HistoryGetEntry API                               * 
**************************************************************** 
* PROBLEM DESCRIPTION:                                         * 
* See error description                                        * 
**************************************************************** 
* RECOMMENDATION:                                              * 
* memset the db2HistoryData struct before passing it to        * 
* db2HistoryGetEntry.                                          * 
****************************************************************
Local Fix:
The fix is to memset the db2HistoryData struct every time before 
calling db2HistoryGetEntry.
available fix packs:
DB2 Version 9.7 Fix Pack 4 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 5 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 6 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 7 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 8 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 9 for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 9a for Linux, UNIX, and Windows
DB2 Version 9.7 Fix Pack 10 for Linux, UNIX, and Windows

Solution
Fix in v97 fp 4
Workaround
not known / see Local fix
Timestamps
Date  - problem reported    :
Date  - problem closed      :
Date  - last modified       :
21.01.2011
28.04.2011
28.04.2011
Problem solved at the following versions (IBM BugInfos)
9.7.FP4
Problem solved according to the fixlist(s) of the following version(s)
9.7.0.4 FixList