Commit Graph

6 Commits

Author SHA1 Message Date
Gerald Combs cd1ddf6ef5 Speed up print_line_text.
isatty adds a small delay, at least on OS X. Call it only when we
allocate a stream. Do the same for our codeset check.

Change-Id: Id3a20059dbc9cf7d5db16d8d238d038b9de0ebf2
Reviewed-on: https://code.wireshark.org/review/16222
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-06-30 19:21:04 +00:00
Gerald Combs bda417a54f Use g_get_charset instead of g_get_codeset.
From Guy via
https://www.wireshark.org/lists/wireshark-dev/201605/msg00027.html

Change-Id: I7884cecb6cd87f474ecc3f84253797fe57f62487
Reviewed-on: https://code.wireshark.org/review/15421
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-14 07:59:46 +00:00
Gerald Combs ae4a912af0 TShark: Convert TTY output.
If we detect that we're writing to a TTY and that it doesn't support
UTF-8, convert our output to the current code page on UNIX/Linux or
to UTF-16LE on Windows. This helps to ensure that we don't fill users'
screens with mojibake, along with scrubbing invalid output.

Add a note about our output behavior to the TShark man page. Add a note
about the glyphs we should and shouldn't be using to utf8_entities.h.

Bug: 12393

Change-Id: I52b6dd240173b80ffb6d35b5950a46a565c97ce8
Reviewed-on: https://code.wireshark.org/review/15277
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-09 04:11:29 +00:00
Bill Meier 454fd6e9eb Add "Editor modelines"; Adjust whitespace as needed.
Change-Id: Ic5a5acb0f36d3aa144edbfb1ae71097b18426db4
Reviewed-on: https://code.wireshark.org/review/6216
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2015-01-02 00:49:09 +00:00
Guy Harris 6e1214c4df Fix comments.
Change-Id: I3b7340939b8204102bfc7e2e7d83f4d978cf7bad
Reviewed-on: https://code.wireshark.org/review/5437
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-11-22 03:32:58 +00:00
Guy Harris 7d7fc47a2a Split the low-level print stream code into a separate file.
Put the low-level print stream code from epan/print.c into
epan/print_stream.c, leaving the higher-level stuff in print.c

Change-Id: Iae961f168ec655a29f434257b1af0937fca9f025
Reviewed-on: https://code.wireshark.org/review/5436
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-11-22 03:24:17 +00:00