this was on the news yesterday
Both the iPhone, shown here, and Google's Android phones are coming under increasing fire for collecting users' location-based data and transmitting the information back to Apple and to Google.
and the Ipad..

By [URL=http://profile.imageshack.us/user/disturbedcomputer]disturbedcomputer[/URL] at 2011-04-22
this is outrageous i'm Glad I don't have any of those 3
A hidden feature located on iPhones is said to track the precise location of the phone's user, pinpointing the person's whereabouts every minute of every day. Joe Brown of Gizmodo joins msnbc to discuss the feature.
here is iPhones secret file that's tracking you NONE STOP (consolidated.db) it's Hidden
you have to Jail break your iPhone with
this will delete the file (consolidated.db) in the background
here are 2 video links (A must Watch if you value your privacy)
one link 2 video's
http://digitallife.today.com/_news/2011/04/20/6501660-your-iphone-is-secretly-tracking-you-all-the-time
oh it's keeps this Info for a year
EDIT
This open-source application maps the information that your iPhone is recording about your movements.
It doesn't record anything itself, it only displays files that are already hidden on your computer.