Gnasher:
The program looks for a minus sign, this is the beginning of the incoming
temperatures from Sim800 module (i.e.)" -9 -22 " or, " -10 -25 " or, " -23 -32 ". The temperature always starts with a minus sign.
Have you the ability to change the format in which the data is sent to the Arduino? If so I suggest you change it to "<-9-22>" and use the system in the 3rd example in Serial Input Basics to receive it.
If you can't change the format can you tell us if each message is followed by a linefeed or carriage-return character? If it is then you could use the system in my 2nd example to receive the data.
And if you look at the parse example you will see that it uses a comma as the separator between values. You can easily change that to a minus.
...R