ascend: add a couple of comments.

Change-Id: I92a84087122e3997f7d2481f82f955987cf8f8dd
Reviewed-on: https://code.wireshark.org/review/37494
Reviewed-by: Guy Harris <gharris@sonic.net>
This commit is contained in:
Guy Harris 2020-06-17 03:27:24 -07:00
parent 77d94aea24
commit 5336ae7d84
1 changed files with 5 additions and 3 deletions

View File

@ -219,8 +219,8 @@ wtap_open_return_val ascend_open(wtap *wth, int *err, gchar **err_info)
offset = ascend_find_next_packet(wth, err, err_info);
if (offset == -1) {
if (*err != 0 && *err != WTAP_ERR_SHORT_READ)
return WTAP_OPEN_ERROR;
return WTAP_OPEN_NOT_MINE;
return WTAP_OPEN_ERROR; /* read error */
return WTAP_OPEN_NOT_MINE; /* EOF */
}
/* Do a trial parse of the first packet just found to see if we might
@ -415,8 +415,10 @@ static gboolean ascend_read(wtap *wth, wtap_rec *rec, Buffer *buf, int *err,
return FALSE;
offset = ascend_find_next_packet(wth, err, err_info);
if (offset == -1)
if (offset == -1) {
/* EOF or read error */
return FALSE;
}
if (!parse_ascend(ascend, wth->fh, rec, buf, wth->snapshot_length,
&ascend->next_packet_seek_start, err, err_info))
return FALSE;