~ubuntu-branches/ubuntu/vivid/nodejs/vivid

« back to all changes in this revision

Viewing changes to deps/v8/src/platform-solaris.cc

  • Committer: Package Import Robot
  • Author(s): Jérémy Lal
  • Date: 2013-11-13 23:17:51 UTC
  • mfrom: (1.1.29)
  • mto: This revision was merged to the branch mainline in revision 33.
  • Revision ID: package-import@ubuntu.com-20131113231751-m6uqywp5dc4s4fxo
Tags: 0.10.22~dfsg1-1
* Upstream update. 
* Refresh patches.

Show diffs side-by-side

added added

removed removed

Lines of Context:
125
125
 
126
126
 
127
127
double OS::LocalTimeOffset() {
128
 
  // On Solaris, struct tm does not contain a tm_gmtoff field.
129
 
  time_t utc = time(NULL);
130
 
  ASSERT(utc != -1);
131
 
  struct tm* loc = localtime(&utc);
132
 
  ASSERT(loc != NULL);
133
 
  return static_cast<double>((mktime(loc) - utc) * msPerSecond);
 
128
  tzset();
 
129
  return -static_cast<double>(timezone * msPerSecond);
134
130
}
135
131
 
136
132