core/gatt: Reset value in db when caching
core/gatt: Reset value in db when caching

After an attribute value is read, changes in the attribute value length
may cause incorrect bytes to remain in the database if the value is not
properly truncated. This patch addresses this by resetting the attribute
value before storing an updated value.

pkarasev3/bluez,mapfau/bluez,ComputeCycles/bluez,pstglia/external-bluetooth-bluez,ComputeCycles/bluez,ComputeCycles/bluez,silent-snowman/bluez,silent-snowman/bluez,silent-snowman/bluez,pkarasev3/bluez,silent-snowman/bluez,mapfau/bluez,mapfau/bluez,mapfau/bluez,pkarasev3/bluez,pstglia/external-bluetooth-bluez,pstglia/external-bluetooth-bluez,ComputeCycles/bluez,pstglia/external-bluetooth-bluez,pkarasev3/bluez