You know, because of my attitude to the misuse of authority, I just automatically assume I am going to end up in a Saudi jail every time I travel there. However, I have found that deferential persistence always pays off in Saudi Arabia, and that "Khalas" (We're done) and "Khalas, Kharooj! (We're done, Get out!) are merely opportunities to continue negotiating.
I did not bring this up earlier, because there are too many variables involved, but I have been able to convince Immigration officers at JED to extend a 24 hour transit visa into a 7 day visa w/ Makkah and Madinnah travel permitted. It took an hour to convince them and two more hours to execute, but the formalities were completed cheerfully. Having said that I do think OP should absolutely resolve his issues before departure, if possible.