Turns out that this was a regression in Debian, already fixed there in
sid 5.4.4-6 and experimental 5.4.6-2.

** Description changed:

  An upstream change in PHP requires php.ini to have the timezone set in
  there, instead of PHP using the system timezone as one might expect.
  
  This is new in PHP 5.4.
  
  Not affected: 5.3.10-1ubuntu3.4 (Precise)
  Affected: 5.4.6-1ubuntu1 (Quantal)
+ Not affected: 5.4.4-7 (sid)
  
  Workaround: edit /etc/php5/*/php.ini, uncomment the "date.timezone" line
  and set it to what you need.
  
  Test Case:
  
  Run:
-     $ php -r 'echo date_default_timezone_get()."\n";'
+     $ php -r 'echo date_default_timezone_get()."\n";'
  
  Expected results: timezone (eg. "UTC")
  
  Actual results:
  PHP Warning:  date_default_timezone_get(): It is not safe to rely on the 
system's timezone settings. You are *required* to use the date.timezone setting 
or the date_default_timezone_set() function. In case you used any of those 
methods and you are still getting this warning, you most likely misspelled the 
timezone identifier. We selected the timezone 'UTC' for now, but please set 
date.timezone to select your timezone. in Command line code on line 1
  UTC
  
  (where in this case UTC is the system timezone).

** Bug watch added: Debian Bug tracker #673763
   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=673763

** Also affects: php5 (Debian) via
   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=673763
   Importance: Unknown
       Status: Unknown

** Summary changed:

- php packaging does not automatically set timezone in php.ini
+ Regression in system fallback for date_default_timezone_get()

** Description changed:

  An upstream change in PHP requires php.ini to have the timezone set in
  there, instead of PHP using the system timezone as one might expect.
  
  This is new in PHP 5.4.
  
  Not affected: 5.3.10-1ubuntu3.4 (Precise)
  Affected: 5.4.6-1ubuntu1 (Quantal)
  Not affected: 5.4.4-7 (sid)
  
  Workaround: edit /etc/php5/*/php.ini, uncomment the "date.timezone" line
  and set it to what you need.
  
  Test Case:
  
  Run:
      $ php -r 'echo date_default_timezone_get()."\n";'
  
- Expected results: timezone (eg. "UTC")
+ Expected results: timezone (eg. "Europe/London")
  
  Actual results:
  PHP Warning:  date_default_timezone_get(): It is not safe to rely on the 
system's timezone settings. You are *required* to use the date.timezone setting 
or the date_default_timezone_set() function. In case you used any of those 
methods and you are still getting this warning, you most likely misspelled the 
timezone identifier. We selected the timezone 'UTC' for now, but please set 
date.timezone to select your timezone. in Command line code on line 1
  UTC
  
  (where in this case UTC is the system timezone).

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to php5 in Ubuntu.
https://bugs.launchpad.net/bugs/1069529

Title:
  Regression in system fallback for date_default_timezone_get()

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/php5/+bug/1069529/+subscriptions

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs

Reply via email to