Tire size difference

I encountered an emergency situation that required the swift replacement of two rear tires. The sole shop in town that had the requisite tires was a used tire shop. Upon purchasing two tires from them, I discovered that they had installed a tire with the incorrect specification - 215/40R17 rather than the necessary 245/40R17 for my Mercedes C250. While the shop owner maintained that this would not pose a problem, my neighbor has raised concerns. Should I avoid operating my vehicle with this undersized tire?