When you are making a film about Afghan refugees fleeing the hellish camps strung out along Pakistan's lawless north-west frontier while B-52 bombers are pummelling the Tora Bora caves just over the mountains you have more important things to worry about than life imitating art.
But that is just what has happened to Michael Winterbottom, the award-winning director of Welcome to Sarajevo, Wonderland and 24 Hour Party People.
One of the two young Afghan stars of In This World, which follows two friends making the arduous 4,000-mile journey overland to London with people traffickers, has since turned up in Britain to claim asylum. Jamal Udin Torabi is 15. A few days after he returned to Pakistan when filming ended, his widowed mother decided the $7,000 (£4,500) he earned as an actor was best spent trying to get him back to Britain where one day he might be able to earn enough to support his four siblings.
Until Jamal caught the eye of a casting agent in Peshawar he had been earning $6 a week in a brick factory, subsisting like the other 1 million refugees in the semi-permanent camps around the city on the daily family ration of 480g of flour and 60g of pulses.
With a only a few days left on his British visa - a visa the film crew could only obtain by buying a forged Pakistani one on the instructions of the authorities there - Jamal flew to Paris before being marched off to a detention centre by immigration officials when he arrived at London Waterloo on the Eurostar train.
He became one of the 3,676 children who asked for asylum here in the first six months of the year.
But, although Jamal was granted exceptional leave to remain here for the next two and a half years, under new guidelines, experts expect he will be deported to Afghanistan, a country he has never set foot in, not long after his 18th birthday.
This harrowing human dilemma was not what Winterbottom had in mind when he set out to make the film, which premieres on November 17 at the London Film Festival.
While Stephen Frears' acclaimed new film, Dirty Pretty Things, which opens the festival on Wednesday, shows the lives of illegal immigrants once they reach Britain, Winterbottom wanted to show why they made the journey.
When 58 Chinese immigrants suffocated in a sealed container at Dover docks two years ago Winterbottom asked himself why so many people risk their lives for the chance to skivvy below the minimum wage in Britain. "When you see refugees in the street, you forget about the lives they have led elsewhere, and the incredible risks they have taken to get here," he said.
"It cost us with our papers and British passports £800 to get to Pakistan, but it costs an Afghan refugee £10,000 - a vast amount for their families - and a good deal of risk to come here."
To feel at first hand a little of what immigrants go through, Winterbottom and scriptwriter Tony Grisoni found themselves in the Shamshatoo refugee camp near Peshawar a few weeks after the fall of Kabul.
From there they travelled most of a route used by people traffickers to Europe. They returned two months later and shot the film "as real".
In the film the two young Afghan actors and their Iranian Kurdish companions are locked into a container and placed aboard a ferry bound for the Italian port of Trieste. Not all survive the journey. Earlier on they are also shot at by soldiers in a blizzard crossing the mountains between Iran and Turkey.
Both incidents come directly from stories Winterbottom and Grisoni gathered on the road. There was no shortage of material.
"We met many Iranian Kurds in Turkey. The border there is completely open, but the rules of the system are that you have to cross illegally to be a refugee so they have to pay smugglers to get them across these very dangerous mountains passes."
Ironically, Jamal's co-star, Enayatullah Jumadin, 22, who the British high commission in Pakistan had warned would "disappear as soon as he arrives in Britain", could not wait to get back to Pakistan and his family.
Winterbottom said he hoped the film might lead people to question the negative connotations the word immigration carries rather than focus on Jamal, who only contacted the film company two months after returning to Britain. "America has become the country it is through welcoming immigrants. It is ludicrous to think that people coming here weakens us. It doesn't, it enriches even at the most boring economic level.
"When it only takes 10 hours in a plane to get to a better life, and you can watch what you are missing on satellite TV, in the end people are going to want the freedom to move. You can't hold them back."
For Jamal, however, change will probably not come quickly enough.
Since David Blunkett changed asylum rules after publishing his white paper last year, the outlook is bleak, according to Terry Smith, head of the children's section of the Refugee Council. "Jamal has exceptional leave to stay... but what do you do with a child in that period? How do you plan his future not knowing where he will end up?
"I am not saying that children should get asylum just because they are children, but we have some responsibilities."