bugDatabase-driven manual pager suite - Bugs: bug #49473, 'man -Thtml' fails to generate...

 
 

bug #49473: 'man -Thtml' fails to generate embedded .png files

Submitter:  None
Submitted:  Sat 29 Oct 2016 12:19:15 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open
* Mandatory Fields

Add a New Comment Rich Markup
   

Sat 29 Oct 2016 12:19:15 PM UTC, original submission:  

```
$ man -Thtml 1 man >man.html
Calling `pnmcut 150 479 485 151 < /tmp/groff-page-umqrKe | pnmcrop -quiet | pnmtopng -background rgb:f/f/f -transparent rgb:f/f/f > grohtml-196661.png
' returned status 256
Calling `pnmcut 150 819 371 102 < /tmp/groff-page-umqrKe | pnmcrop -quiet | pnmtopng -background rgb:f/f/f -transparent rgb:f/f/f > grohtml-196662.png
' returned status 256
Calling `pnmcut 200 416 264 88 < /tmp/groff-page-umqrKe | pnmcrop -quiet | pnmtopng -background rgb:f/f/f -transparent rgb:f/f/f > grohtml-196663.png
' returned status 256
```

This successfully generates `man.html`, but fails to generate the embedded `.png` files.

I've tracked this problem down to the `chdir()` in the `display()` function in `man.c`. It changes the cwd to `/usr/share/man` (on my system at least). This prevents the `pnmtopng ... >grohtml-196661.png` command from working, since that has no write access to `/usr/share/man`, and of course it shouldn't be writing the file there anyway.

Simply commenting out the `chdir()` makes this particular case work. But I don't know what else that will break.

Note: the pnmcut/pnmcrop/pnmtopng pipeline gets run by `groff`, which in turn gets run by `man`.

Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by c4rlo (I entered this bug)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-10-29 c4rlo Carbon-Copy- Added c4rlo

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code