| 2966 | |
| 2967 | |
| 2968 | void Batch::addBlobStream(CheckStatusWrapper* status, unsigned length, const void* inBuffer) |
| 2969 | { |
| 2970 | try |
| 2971 | { |
| 2972 | // Check and validate handles, etc. |
| 2973 | if (!stmt) |
| 2974 | { |
| 2975 | Arg::Gds(isc_bad_req_handle).raise(); |
| 2976 | } |
| 2977 | |
| 2978 | // Policy check |
| 2979 | if (blobPolicy != IBatch::BLOB_STREAM) |
| 2980 | { |
| 2981 | (Arg::Gds(isc_batch_policy) << "addBlobStream").raise(); |
| 2982 | } |
| 2983 | |
| 2984 | Rsr* statement = stmt->getStatement(); |
| 2985 | CHECK_HANDLE(statement, isc_bad_req_handle); |
| 2986 | Rdb* rdb = statement->rsr_rdb; |
| 2987 | CHECK_HANDLE(rdb, isc_bad_db_handle); |
| 2988 | rem_port* port = rdb->rdb_port; |
| 2989 | RefMutexGuard portGuard(*port->port_sync, FB_FUNCTION); |
| 2990 | |
| 2991 | // Store stream data |
| 2992 | putBlobData(length, inBuffer); |
| 2993 | |
| 2994 | batchActive = true; |
| 2995 | } |
| 2996 | catch (const Exception& ex) |
| 2997 | { |
| 2998 | ex.stuffException(status); |
| 2999 | } |
| 3000 | } |
| 3001 | |
| 3002 | |
| 3003 | void Batch::sendBlobPacket(unsigned size, const UCHAR* ptr, bool flash) |
no test coverage detected