X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=yaffs_tagsmarshall.c;h=d568208e91bd53ece6b685707ecca481c693c183;hp=bcd6f242dc256d999c2cc22ac6cd77fd3b1aa11f;hb=HEAD;hpb=e1cc6e41366587ff0bdb7e246b5f17d230c13226 diff --git a/yaffs_tagsmarshall.c b/yaffs_tagsmarshall.c index bcd6f24..397715d 100644 --- a/yaffs_tagsmarshall.c +++ b/yaffs_tagsmarshall.c @@ -100,8 +100,12 @@ static int yaffs_tags_marshall_read(struct yaffs_dev *dev, BUG(); - if (retval == YAFFS_FAIL) + if (retval == YAFFS_FAIL) { + if (local_data) + yaffs_release_temp_buffer(dev, data); + return YAFFS_FAIL; + } if (dev->param.inband_tags) { if (tags) { @@ -172,10 +176,7 @@ static int yaffs_tags_marshall_query_block(struct yaffs_dev *dev, int block_no, "block query returns seq %d state %d", *seq_number, *state); - if (retval == 0) - return YAFFS_OK; - else - return YAFFS_FAIL; + return retval; } static int yaffs_tags_marshall_mark_bad(struct yaffs_dev *dev, int block_no)