Commit cdf907c49b1427dea1639e76abfbe3f30e52bf33
1 parent
a30beafb
janus tweak
Showing
2 changed files
with
2 additions
and
2 deletions
openbr/janus.cpp
| @@ -67,7 +67,7 @@ janus_error janus_augment(const janus_image image, const janus_attribute_list at | @@ -67,7 +67,7 @@ janus_error janus_augment(const janus_image image, const janus_attribute_list at | ||
| 67 | Template u; | 67 | Template u; |
| 68 | transform->project(t, u); | 68 | transform->project(t, u); |
| 69 | template_->append(u); | 69 | template_->append(u); |
| 70 | - return u.isEmpty() ? JANUS_FAILURE_TO_ENROLL : JANUS_SUCCESS; | 70 | + return (u.isEmpty() || !u.first().data) ? JANUS_FAILURE_TO_ENROLL : JANUS_SUCCESS; |
| 71 | } | 71 | } |
| 72 | 72 | ||
| 73 | janus_error janus_finalize_template(janus_template template_, janus_flat_template flat_template, size_t *bytes) | 73 | janus_error janus_finalize_template(janus_template template_, janus_flat_template flat_template, size_t *bytes) |