This is a commonly-occurring problem, in the recent release days of Pokemon Go. Short of sending Niantic a bug report, there is unfortunately nothing you can do.
Even with submitting a bug, you increase the chances of this issue being fixed more quickly, but there is little chance Niantic will be able to reimburse you with the lost pokemon1.
While more of a 'band-aid solution', consider closing all other applications with an application manager2, before playing Pokemon Go. There appears to be a higher chance of crashing if you have less memory accessible to the main game, and it can't hurt. Once again, this will fix the problem before it starts, but only in very minute situations.
For further reference, this sort of bug appears to happen semi-frequently. Many users have reported the problem, on Reddit, with no raised solution. I have found more users confirming a similar experience, on GameFAQs. They appear to actually catch the pokemon, but it seems they were still not rewarded the catching experience. This suggests the bug is a result of the game failing to communicate with the servers, in time, and getting lucky in regards to whether the crash occurred before or after registering the catch.
1 Consider that there is really no way for Niantic Labs to know that you actually did catch the pokemon, given that the problem arises from failure to confirm the successful catch, in the first place. They would try to fix the problem, but would unlikely risk giving free pokemon away to the few users that submitted fake "I almost caught a MewTwo!" reports.
2 Ensure you use an application manager, wether it be a seperate application, or a built in function of your phone. Applications are generally designed to run in the background, when you choose to close them; They do not actually 'close'. I have seen this lead to many obscure issues, especially with phones that contain less internal memory.