diff options
author | seungha.son <seungha.son@samsung.com> | 2017-04-12 17:24:14 +0900 |
---|---|---|
committer | seungha.son <seungha.son@samsung.com> | 2017-04-12 17:31:39 +0900 |
commit | 00b34a6e66f3f9c67c08996abf19e651e8607737 (patch) | |
tree | 6bdddd2182bfd9802e828f1412c36ee99d3841a9 /src/notification_noti.c | |
parent | f293658db50d5ce66483bc5a142ace9e0f9be540 (diff) | |
download | notification-00b34a6e66f3f9c67c08996abf19e651e8607737.tar.gz notification-00b34a6e66f3f9c67c08996abf19e651e8607737.tar.bz2 notification-00b34a6e66f3f9c67c08996abf19e651e8607737.zip |
Fix error that set priv id
Signed-off-by: seungha.son <seungha.son@samsung.com>
Change-Id: I15c7d124ed0f3162bba8c6b2a4c928275554805b
Diffstat (limited to 'src/notification_noti.c')
-rwxr-xr-x | src/notification_noti.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/notification_noti.c b/src/notification_noti.c index 75dd89d..efdbf00 100755 --- a/src/notification_noti.c +++ b/src/notification_noti.c @@ -986,10 +986,12 @@ EXPORT_API int notification_noti_insert(notification_h noti) } ret = sqlite3_step(stmt); - if (ret == SQLITE_OK || ret == SQLITE_DONE) + if (ret == SQLITE_OK || ret == SQLITE_DONE) { + noti->priv_id = (int)sqlite3_last_insert_rowid(db); ret = NOTIFICATION_ERROR_NONE; - else + } else { ret = NOTIFICATION_ERROR_FROM_DB; + } err: if (stmt) |