[Rpm-maint] [rpm-software-management/rpm] rpm2cpio and rpm2archive: don't write archive data to a terminal. (#116)

Peter Jones notifications at github.com
Thu Jan 5 22:13:22 UTC 2017


rpm2cpio and rpm2archive happily write binary data to the output
terminal.  This happens, for example, when I'm typing a command such as
"rpm2cpio foo.rpm | less" and I make a typo, hitting <Return> instead of
the pipe key.  This often results in hilarious (if bewildering) font and
character encoding changes.  On some systems, this can even result in
installation of relatively arbitrary rpms!

Nobody has ever meant to do this, and it's easy to prevent, so that's
what this patch does.

Signed-off-by: Peter Jones <pjones at redhat.com>
Reviewed-by: Adam Jackson <ajax at redhat.com>
You can view, comment on, or merge this pull request online at:

  https://github.com/rpm-software-management/rpm/pull/116

-- Commit Summary --

  * rpm2cpio and rpm2archive: don't write archive data to a terminal.

-- File Changes --

    M rpm2archive.c (6)
    M rpm2cpio.c (4)

-- Patch Links --

https://github.com/rpm-software-management/rpm/pull/116.patch
https://github.com/rpm-software-management/rpm/pull/116.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/116
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20170105/e915a5ca/attachment-0001.html>


More information about the Rpm-maint mailing list