|Anonymous | Login | Signup for a new account||04-21-2019 07:30 PDT|
|Main | My View | View Issues | Change Log | Docs|
|Viewing Issue Simple Details [ Jump to Notes ]||[ View Advanced ] [ Issue History ] [ Print ]|
|ID||Category||Severity||Reproducibility||Date Submitted||Last Update|
|0001966||[Quercus]||minor||always||08-22-07 23:55||11-16-07 18:29|
|Summary||0001966: Drupal 5.2 + locale module + Swedish translation => StackOverflowError|
The first request for a Swedish page will render almost ok. I had some issues with unicode characters not displaying correctly. The subsequent requests always cause a StackOverflowError.
On the first request for a Swedish node Drupal will read the sv texts from the locale_target table into a PHP associative array which it then serializes and saves to the cache table. Then it will generate the Swedish menu structure and serialize it and save to the cache_menu table. AFAICS the problem is when Drupal on the susequent requests tries to unserialize the previously serialized object from cache_menu. The unserialize fails and Drupal's menu functions loops indefinitely until StackOverflowError is generated.
If you have a look in the cache_menu blob you can clearly see that Swedish UTF-8 characters which normally occupy 2 bytes now need 4 bytes. The length field in the serialized strings are incorrect which I guess causes the problem with unserialize.
I've tried changing the function db_encode_blob() in includes/database.mysql.inc to
return "x'" . bin2hex($data) . "'";
That change combined with settings all encoding properties to ISO8859-1 makes the data in cache_menu become ISO8859-1 encoded. The length fields in the serialized data are however still incorrect.
I've tried with all combinations of script-encoding, unicode.runtime_encoding and unicode.output_encoding. Setting all to ISO8859-1 solved the problems I had with the unicode characters not displaying correctly on the first request. But it didn't solve the problem with StackOverflowError.
I'm using the following JDBC URL otherwise I cannot save Swedish blog entries (I get an SQLException whenever I try to):
java version "1.6.0"
Java(TM) SE Runtime Environment (build 1.6.0-b105)
Java HotSpot(TM) Client VM (build 1.6.0-b105, mixed mode, sharing)
Linux 2.6.20-15-generic 0000002 SMP Sun Apr 15 07:36:31 UTC 2007 i686 GNU/Linux
|This appears to be the same issue as 1955, using postgres.|
Closing since this issue is a duplicate of 1955. That issue
was just fixed in the Postgres DB layer. This fix will be
available in the next release.
|08-22-07 23:55||ntherning||New Issue|
|08-23-07 11:50||gjvc||Note Added: 0002225|
|11-16-07 18:29||mo||Status||new => closed|
|11-16-07 18:29||mo||Note Added: 0002502|
|11-16-07 18:29||mo||Resolution||open => fixed|
|11-16-07 18:29||mo||Fixed in Version||=> 3.1.4|
| Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
33 total queries executed.|
29 unique queries executed.