summaryrefslogtreecommitdiff
path: root/src/adb.c
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2021-07-17 15:09:20 +0300
committerTimo Teräs <timo.teras@iki.fi>2021-07-22 15:30:08 +0300
commit94c5e01038a819e8abd062ed81aec321cdff4aa3 (patch)
treeea420386ef62e67be935cd1dd3d167083abd13dd /src/adb.c
parent3b00c0dc808f4b6c3809c91a67709ca2d7bf8865 (diff)
downloadapk-tools-94c5e01038a819e8abd062ed81aec321cdff4aa3.tar.gz
apk-tools-94c5e01038a819e8abd062ed81aec321cdff4aa3.tar.bz2
apk-tools-94c5e01038a819e8abd062ed81aec321cdff4aa3.tar.xz
apk-tools-94c5e01038a819e8abd062ed81aec321cdff4aa3.zip
adb: remove the now unused get_default_int() hook
It is no longer needed, and can be later reintroduced if needed.
Diffstat (limited to 'src/adb.c')
-rw-r--r--src/adb.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/adb.c b/src/adb.c
index 3a7c684..640f01b 100644
--- a/src/adb.c
+++ b/src/adb.c
@@ -384,10 +384,7 @@ adb_val_t adb_ro_val(const struct adb_obj *o, unsigned i)
uint32_t adb_ro_int(const struct adb_obj *o, unsigned i)
{
- adb_val_t val = adb_ro_val(o, i);
- if (val == ADB_NULL && o->schema && o->schema->get_default_int)
- return o->schema->get_default_int(i);
- return adb_r_int(o->db, val);
+ return adb_r_int(o->db, adb_ro_val(o, i));
}
apk_blob_t adb_ro_blob(const struct adb_obj *o, unsigned i)
@@ -826,9 +823,6 @@ adb_val_t adb_wo_val_fromstring(struct adb_obj *o, unsigned i, apk_blob_t val)
adb_val_t adb_wo_int(struct adb_obj *o, unsigned i, uint32_t v)
{
- if (o->schema && o->schema->get_default_int &&
- v == o->schema->get_default_int(i))
- return ADB_NULL;
return adb_wo_val(o, i, adb_w_int(o->db, v));
}