summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
Diffstat (limited to 'src/map')
-rw-r--r--src/map/map.c4
-rw-r--r--src/map/vending.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/src/map/map.c b/src/map/map.c
index d3d7ac65d..cbef8ca95 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -1622,6 +1622,10 @@ int map_quit(struct map_session_data *sd) {
}
}
+ if( sd->state.vending ) {
+ idb_remove(vending->db, sd->status.char_id);
+ }
+
party->booking_delete(sd); // Party Booking [Spiria]
pc->makesavestatus(sd);
pc->clean_skilltree(sd);
diff --git a/src/map/vending.c b/src/map/vending.c
index 2784d46a2..32e084a87 100644
--- a/src/map/vending.c
+++ b/src/map/vending.c
@@ -283,7 +283,7 @@ void vending_openvending(struct map_session_data* sd, const char* message, const
clif->openvending(sd,sd->bl.id,sd->vending);
clif->showvendingboard(&sd->bl,message,0);
- idb_put(vending->db, sd->vender_id, sd);
+ idb_put(vending->db, sd->status.char_id, sd);
}