From fa82dab8db28b3d479698a49bea037f3bf31f82b Mon Sep 17 00:00:00 2001 From: Ben Winston Date: Sat, 11 May 2024 15:08:00 -0400 Subject: add isbn and translator --- booki.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/booki.c b/booki.c index 7613495..96e9392 100644 --- a/booki.c +++ b/booki.c @@ -116,6 +116,14 @@ struct Book parse_book(char* current_pos) { struct es language = parse_string(current_pos, &new_pos); book.language = language; current_pos = new_pos; + } else if (strncmp(attr, "isbn", 4) == 0) { + struct es isbn = parse_string(current_pos, &new_pos); + book.isbn = isbn; + current_pos = new_pos; + } else if (strncmp(attr, "translator", 10) == 0) { + struct es translator = parse_string(current_pos, &new_pos); + book.translator = translator; + current_pos = new_pos; } // go to (and then past) the newline -- cgit v1.2.3