diff options
author | horchi <vdr@jwendel.de> | 2017-03-19 11:19:52 +0100 |
---|---|---|
committer | horchi <vdr@jwendel.de> | 2017-03-19 11:19:52 +0100 |
commit | 577b2c73f353f3528af4214808284cb6ac3ced31 (patch) | |
tree | ce51f6ee7ee10799172dd2255ff9a9cee03a9830 /lib/db.c | |
parent | a83bbb05ae4b3bcfc0a63f60c84d6f3027fb1d4e (diff) | |
download | vdr-plugin-epg2vdr-577b2c73f353f3528af4214808284cb6ac3ced31.tar.gz vdr-plugin-epg2vdr-577b2c73f353f3528af4214808284cb6ac3ced31.tar.bz2 |
minor change
Diffstat (limited to 'lib/db.c')
-rw-r--r-- | lib/db.c | 15 |
1 files changed, 9 insertions, 6 deletions
@@ -737,15 +737,18 @@ int cDbTable::init(int allowAlter) // check/create table ... - if (exist() && allowAlter) - validateStructure(allowAlter); + if (allowAlter) + { + if (exist()) + validateStructure(allowAlter); - if (createTable() != success) - return fail; + if (!exist() && createTable() != success) + return fail; - // check/create indices + // check/create indices - createIndices(); + createIndices(); + } // ------------------------------ // prepare BASIC statements |