diff options
Diffstat (limited to 'booki.c')
| -rw-r--r-- | booki.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -32,6 +32,7 @@ static const DataField BOOK_FIELDS[] = { { "language", booki_string, true }, { "translator", booki_string, true }, { "on", booki_string, true }, + { "genre", booki_string, true }, { "id", booki_number, false }, { "_other", booki_raw, false } }; @@ -402,6 +403,7 @@ struct Book { ES language; ES translator; ES on; + ES genre; int published; // catch-all @@ -417,6 +419,7 @@ void init_book(BOOK* book) { book->language = default_es; book->translator = default_es; book->on = default_es; + book->genre = default_es; book->published = 0; book->_other = default_es; @@ -437,6 +440,8 @@ ES* get_string_field(BOOK* book, char* name) { return &(book->translator); else if (ATTR_MATCH(name, "on")) return &(book->on); + else if (ATTR_MATCH(name, "genre")) + return &(book->genre); else if (ATTR_MATCH(name, "_other")) return &(book->_other); else |
