| 134 | } |
| 135 | |
| 136 | bool DTransaction::prepareCommit(CheckStatusWrapper* status, TdrBuffer& tdr) |
| 137 | { |
| 138 | TEXT host[64]; |
| 139 | ISC_get_host(host, sizeof(host)); |
| 140 | const UCHAR hostlen = static_cast<UCHAR>(strlen(host)); |
| 141 | |
| 142 | // Build a transaction description record containing the host site and database/transaction |
| 143 | // information for the target databases. |
| 144 | tdr.clear(); |
| 145 | tdr.add(TDR_VERSION); |
| 146 | tdr.add(TDR_HOST_SITE); |
| 147 | tdr.add(hostlen); |
| 148 | tdr.add(reinterpret_cast<UCHAR*>(host), hostlen); |
| 149 | |
| 150 | // Get database and transaction stuff for each sub-transaction. |
| 151 | |
| 152 | for (unsigned i = 0; i < sub.getCount(); ++i) |
| 153 | { |
| 154 | if (sub[i]) |
| 155 | { |
| 156 | if (! buildPrepareInfo(status, tdr, sub[i])) |
| 157 | return false; |
| 158 | } |
| 159 | } |
| 160 | |
| 161 | return true; |
| 162 | } |
| 163 | |
| 164 | void DTransaction::getInfo(CheckStatusWrapper* status, |
| 165 | unsigned int itemsLength, const unsigned char* items, |
nothing calls this directly
no test coverage detected