title: Android location getTime() always returns big different time
body: <p>I am getting location using Location Manager regulary depending on the setting, 2minutes in testing case and trying to use location.geTime() method. I am not using LocationManager.getLastKnownLocation(). Document says it is UTC time and I converted it to local time like below:</p>
  
  <pre><code>Date d = new Date(location.getTime());
  SimpleDateFormat sdf = new SimpleDateFormat("yyMMddkkmmss';
  sdf.setTimeZone(TimeZone.getTimneZone("UTC");
  sdf.format(d);
  </code></pre>
  
  <p>But I am getting different date from what I expect. Current time I am writing is about 130516155000(2013-05-16 15:50:00) but I am getting 040015130515.
  And I removed the timezone and set the time zone as 'GMT' as well and date fixed but time was quite different. In real device and emulator are same. And I already checked timezone setting in both and they are correct.
  Please tell me what I am missing?</p>
  
  <p>Thanks.</p>
  
  <p>EDIT:</p>
  
  <p>I add more.</p>
  
  <pre><code>Log:
  05-16 16:09:30.227: D/location.getTime()(1279): 1368590417000
  05-16 16:09:30.237: D/NMEAGPRMCTime(1279): 040017
  05-16 16:09:30.247: D/NMEAGPRMCDate(1279): 130515
  </code></pre>
  
  <p>Code:</p>
  
  <pre><code>public static String NMEAGPRMCTime(Date d)
  {
      SimpleDateFormat sdf = new SimpleDateFormat("kkmmss");
      sdf.setTimeZone(TimeZone.getTimeZone("UTC"));
      String result = sdf.format(d);
      Log.d("NMEAGPRMCTime", result);
      return result;
  }
  
  
  public static String NMEAGPRMCDate(Date d)
  {
      SimpleDateFormat sdf = new SimpleDateFormat("yyMMdd");
      sdf.setTimeZone(TimeZone.getTimeZone("UTC"));
      String result = sdf.format(d);
      Log.d("NMEAGPRMCDate", result);
  
      return result;
  }
  </code></pre>
  
  <p>That's it. This is the code exactly what I using.</p>