• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
So little time, so many mistakes to be made...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

So little time, so many mistakes to be made...


  • Subject: So little time, so many mistakes to be made...
  • From: Ray Kiddy <email@hidden>
  • Date: Tue, 16 Jan 2007 23:06:22 -0800


Somehow, it happened. I tried to make the point about fixing the zoneinfo.zip file in JavaFoundation in as simple a manner as I could. Less opportunity for mistakes, right? Wrong. :-)


I found two problems. One was my bad and the other was a bug, I think, that has been hanging around NSTimeZone for quite a while. I am much less able to find existing bug reports these days.

The first problem is that there are files in the /usr/share/zoneinfo file that do not represent time zones. They needed to be filtered out of the zip task.

The second problem is that if one goes through the list of available IDs for available time zones, some of the them fail. I was calling toString() on them and got an NPE. Not good.

The offending time zone IDs are:

	Asia/Riyadh87
	Asia/Riyadh88
	Asia/Riyadh89
	Mideast/Riyadh87
	Mideast/Riyadh88
	Mideast/Riyadh89

The "Asia/Riyadh" time zone works, but none of these other do. I think this is an existing bug, though. I just sounds too familiar.

It turns out the solution to both problems is to filter this stuff out of the zip file.

So, I am updating the project I posted. The fixFoundation target, with the excludes on the zip task, will now look like this:

<target name="fixFoundation">
<tempfile property="temp" />
<mkdir dir="${temp}" />
<unjar src="${jarfile}" dest="${temp}" />
<delete quiet="true" file="${temp}/com/webobjects/foundation/ TimeZoneInfo/zoneinfo.zip" />
<zip destfile="${temp}/com/webobjects/foundation/ TimeZoneInfo/zoneinfo.zip" basedir="${zoneInfoDir}" excludes="*.tab,**/Riyadh87,**/Riyadh88,**/Riyadh89,**/\+VERSION" />
<move file="${jarfile}" tofile="${jarfile}_bak" />
<jar basedir="${temp}" destfile="${jarfile}" />
<delete quiet="true" dir="${temp}" />
</target>


And while we are in the neighborhood, I found out that people may have more copies of the zoneinfo.zip file hanging about.

I am working with a clean install. If you have an upgraded install, you may have copies of the file that are not being used, but have not been removed.

Here is my original list:

/System/Library/Frameworks/JavaFoundation.framework/Resources/Java/ javafoundation.jar
/Library/WebObjects/lib/JavaFoundation.jar (2 copies, one for WebServerResources and one for Resources)
/Library/WebServer/Documents/WebObjects/Java/com/webobjects/ foundation/TimeZoneInfo/zoneinfo.zip (not in a jar file, actually)
/Library/WebServer/Documents/WebObjects/Java/wojavaclient.jar


Here is an expanded list:

/System/Library/Frameworks/JavaFoundation.framework/Resources/Java/ javafoundation.jar
/System/Library/Frameworks/JavaFoundation.framework/ WebServerResources/Java/JavaFoundation.jar
/System/Library/Frameworks/JavaFoundation.framework/ WebServerResources/Java/com/webobjects/foundation/TimeZoneInfo/ zoneinfo.zip
/System/Library/Frameworks/JavaEODistribution.framework/Versions/A/ WebServerResources/Java/wojavaclient.jar
/System/Library/WebObjects/WODocumentRoot/WebObjects/Java/ JavaFoundation.jar
/System/Library/WebObjects/WODocumentRoot/WebObjects/Java/ wojavaclient.jar
/System/Library/WebObjects/WODocumentRoot/WebObjects/Java/com/ webobjects/foundation/TimeZoneInfo/zoneinfo.zip
/System/Library/Java/wojavaclient.jar
/Library/WebObjects/lib/JavaFoundation.jar
/Library/WebServer/Documents/WebObjects/Java/JavaFoundation.jar
/Library/WebServer/Documents/WebObjects/Java/wojavaclient.jar
/Library/WebServer/Documents/WebObjects/Java/com/webobjects/ foundation/TimeZoneInfo/zoneinfo.zip


Yikes!

- ray


_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: daylight saving time problem
      • From: Ken Anderson <email@hidden>
  • Prev by Date: Re: NSUndoManager beginUndoGrouping and endUndoGrouping
  • Next by Date: Re: WOFileUpload with UTF-8 forms
  • Previous by thread: Re: multiple build targets in xcode
  • Next by thread: Re: daylight saving time problem
  • Index(es):
    • Date
    • Thread