The te-form of a verb + しまう has two sences, which at first might appear rather inconruous. One sense it means carries the verb out with determination.
I read the book comletely./ I finished reading the book.
The second sense is lack of control on how things turn out. This is usually pared with a sense of regret, something happens regretably.
I inadvertently left my bag on the train.