Bug 122845 - http link in PDF file to another PDF file opens the PDF file as ASCII in Konqueror (a reload is required to load the PDF view)
Summary: http link in PDF file to another PDF file opens the PDF file as ASCII in Konq...
Status: RESOLVED FIXED
Alias: None
Product: kpdf
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal with 20 votes (vote)
Target Milestone: ---
Assignee: Albert Astals Cid
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-28 18:18 UTC by Christoph
Modified: 2006-07-09 16:26 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christoph 2006-02-28 18:18:39 UTC
Version:           0.5.1 (using KDE 3.5.1, Kubuntu Package 4:3.5.1-0ubuntu0breezy1 )
Compiler:          Target: i486-linux-gnu
OS:                Linux (i686) release 2.6.12-10-686

I generated a PDF file with PDF latex using the url and hyperref packages. If a http link to a PDF file is klicked in KPDF a konqueror window opens and displays the ASCII view of the PDF file. A reload is required to see the actual PDF rendering
Comment 1 Albert Astals Cid 2006-02-28 20:39:53 UTC
Is the linked file local or in a web server?
Comment 2 Christoph 2006-06-26 18:35:15 UTC
It's on a web server
Comment 3 Albert Astals Cid 2006-06-26 23:15:20 UTC
i would say it is probably a local problem or web server misconfiguration, it has worked here for ages.

Are that pdf files you mention freely available so i can test?
Comment 4 Christoph 2006-07-09 03:16:05 UTC
To reproduce the bug open the following file in KPDF:
http://www.whitehouse.gov/OMB/circulars/a004/a-4.pdf
From within KPDF click on the second link (this is the link to:
http://www.whitehouse.gov/omb/memoranda/m00-08.pdf )

What happens for me is, that the ASCII from this PDF file is shown in Konqueror and a reload is required to show the actual PDF. This has happened for me consistently for PDF files on different servers. Furthermore, this does not happen, when I open the PDF in XPDF, so it must be a KPDF bug.
Comment 5 Albert Astals Cid 2006-07-09 16:26:02 UTC
SVN commit 560199 by aacid:

Do not be "too" intelligent and assume a Browse link means html.
See how having an example of things not working makes it much easier to fix.
BUGS: 122845


 M  +2 -6      document.cpp  


--- branches/KDE/3.5/kdegraphics/kpdf/core/document.cpp #560198:560199
@@ -1059,12 +1059,8 @@
                     return;
                 }
 
-                // get service for web browsing
-                KService::Ptr ptr = KServiceTypeProfile::preferredService("text/html", "Application");
-                KURL::List lst;
-                // append 'url' parameter to the service and run it
-                lst.append( url );
-                KRun::run( *ptr, lst );
+		// Albert: this is not a leak!
+		KRun *r = new KRun(url);
             }
             } break;