Delete the specified item ID from the stream, returning 1 if the item * was deleted 0 otherwise (if it does not exist). */
| 1318 | /* Delete the specified item ID from the stream, returning 1 if the item |
| 1319 | * was deleted 0 otherwise (if it does not exist). */ |
| 1320 | int streamDeleteItem(stream *s, streamID *id) { |
| 1321 | int deleted = 0; |
| 1322 | streamIterator si; |
| 1323 | streamIteratorStart(&si,s,id,id,0); |
| 1324 | streamID myid; |
| 1325 | int64_t numfields; |
| 1326 | if (streamIteratorGetID(&si,&myid,&numfields)) { |
| 1327 | streamIteratorRemoveEntry(&si,&myid); |
| 1328 | deleted = 1; |
| 1329 | } |
| 1330 | streamIteratorStop(&si); |
| 1331 | return deleted; |
| 1332 | } |
| 1333 | |
| 1334 | /* Get the last valid (non-tombstone) streamID of 's'. */ |
| 1335 | void streamLastValidID(stream *s, streamID *maxid) |
no test coverage detected