TONT 36053 程序向你抛出了一个问题,但如果作答的话就会爆炸

请注意:本页内容发布于 1709 天前,内容可能已经过时,请注意甄别。

原文链接:https://devblogs.microsoft.com/oldnewthing/20050328-00/?p=36053

JeffDav’s story of a program that didn’t like it when he told it where to install reminded me of another program that we dealt with during Windows 95 development.

JeffDav 上那篇关于某个不喜欢被用户指定安装位置的程序的故事,让我想起我们在 Windows 95 开发过程中曾经面对的另一个程序。

This was a big-name program developed by one of the biggest-of-the-big name software companies. Let’s give this program the imaginary name “LitWare”. Its setup program asked you where you wanted the program to be installed, and it suggested “C:\LITWARE”. If you accepted the default, then everything proceeded normally.

那个程序是某个顶尖有名的大公司开发的某个大品牌,这里我们先给它起个虚构的名字,叫 LitWare。这个应用的安装程序会询问你要将其安装到哪个位置,并顺带建议安装到『C:\LITWARE』。如果你直接采纳这个默认值,那么一切都会很顺利。

However, if you changed the default to anything else, the setup program ran to completion, but the program itself wouldn’t run.

然而,如果你把这个默认值改成其它的路径,那么虽然可以完成安装,但程序本身则无法启动。

Because the program contained the hard-coded path “C:\LITWARE” and insisted that it find its support files in that directory.

因为程序里将路径『C:\LITWARE』进行了硬编码,并坚持在那个路径下面寻找程序的支持文件。

At least Jeff’s program realized that it was about to be installed into a directory where it would fail to work!

至少 Jeff 提到的那个程序还晓得自己要被安装到会造成它没法工作的目录里去呢!

 

附:文章开头提到的 JeffDav 上的文章:《安装的麻烦》(Installation woes)

原文链接:https://docs.microsoft.com/en-us/archive/blogs/jeffdav/installation-woes

After successfully getting Windows XP SP2 installed on my laptop, I started installing other software.

在成功把 Windows XP SP2 安装到我笔记本上之后,我开始安装其它的程序。

This post has nothing to do with IE, but I need to vent.

这篇博文跟 IE 没什么关系,但我还是得发泄一下。

Nameless 3rd Party App: Where do you want to install me? How about c:\nameless?

某第三方应用:你要把我安装到什么地方?C:\nameless 这个路径怎么样?

Jeffdav: How about c:\program files\nameless?

Jeffdav:C:\Program Files\nameless 怎么样?

Nameless 3rd Party App: It is a bad idea to install me somewhere with spaces in the path. Continue anyway?

某第三方应用:把我装到路径里有空格的位置可不是个好主意,还是要继续吗?

Jeffdav: No. Lame. At least it knows it is lame and told me while I still have a chance to do something about it.

Jeffdav:不,算了吧。至少它还知道这样会出事,把这件事告诉了我,让我还有机会做点改变。

Jeffdav: Okay, fine, c:\nameless.

Jeffdav:行吧,那就这样,C:\nameless。

(译注:下面是另一个故事)

Nameless Microsoft App: Installing…

某微软应用:正在安装……

Nameless Microsoft App: Installing… <30 minutes later>

某微软应用:正在安装……(30分钟之后)

Microsoft Windows: You have lost your connection to the wireless LAN! (I was walking to a meeting.)

Windows:无线网络连接不可用!(我正在端着笔记本去开会的路上)

Nameless Microsoft App: Internal Error 3452. [OK]

某微软应用:内部错误3452。(点OK)

Microsoft Windows: You have reconnected to the wireless LAN!

Windows:无线网络已连接!

Jeffdav: <clicks OK>

Jeffdav:(点OK)

Nameless Microsoft App: Uninstalling…

某微软应用:正在卸载……

Nameless Microsoft App: Thanks for playing. Please start from the beginning again.

某微软应用:胜败乃兵家常事,大侠请重新来过。

Of course I did have success stories. Windows was easy to install off the slipstream CD. Putty, as always, was easy to install since setup for putty is simply xcopy.

当然我也成功安装过其它的程序。Windows 从整合好的光盘上安装很简单。Putty 则是一如既往的简单,毕竟只是一行 xcopy 的事。

The moral of this story, I guess, is that Setup is Hard.

我想,这个故事的寓意大概是,安装这件事真难啊。

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

 剩余字数 ( Characters available )

Your comment will be available after auditing.
您的评论将在通过审核后显示。

Please DO NOT add any links in your comment, otherwise it would be identified as SPAM automatically and never be audited.
请不要在评论中插入任何链接,否则将被自动归类为垃圾评论,且永远不会被提交给博主进行复审。

*