Included are two versions of the function. The first is similar to the one you posted and the second is how you can deal with some cases where one is not using a filter and may encounter a peer with no data of interest. In such cases a flag/sentinel is used mark the end of the data in the resultset.
VHF