Skip to content

There is no special color rule in "ls" for Executable && MultiHardLink#5

Closed
lepe wants to merge 2 commits intocoreutils:masterfrom
lepe:master
Closed

There is no special color rule in "ls" for Executable && MultiHardLink#5
lepe wants to merge 2 commits intocoreutils:masterfrom
lepe:master

Conversation

@lepe
Copy link

@lepe lepe commented Dec 7, 2015

Background:
http://unix.stackexchange.com/questions/123138/ls-color-how-to-color-executable-hard-links/247822#247822

Added: "C_EXEC_HARDLINK" and "em" (executable multihardlink) into "ls.c" code.

@pixelb
Copy link
Member

pixelb commented Dec 7, 2015

Thanks a lot for the patch. However I find the coloring of multiply hardlinked files quite arbitrary in the first place. Therefore colors for combinations of such attributes are even less desired IMHO. I find it much more instructive to directly highlight the interesting attribute, which is the number of links >=2 in the ls -l output. You can see that done in the ls wrapper script at http://www.pixelbeat.org/scripts/l

If you feel strongly about this, please bring it up again at [email protected]

@pixelb pixelb closed this Dec 7, 2015
pixelb added a commit to pixelb/coreutils that referenced this pull request Oct 31, 2016
This was detected in about 25% of runs with gcc -fsanitize=address

  ERROR: AddressSanitizer: global-buffer-overflow on address ...
  READ of size 4 at 0x000000416628 thread T0
    #0 0x40479f in genpattern src/shred.c:782
    coreutils#1 0x4050d9 in do_wipefd src/shred.c:921
    coreutils#2 0x406203 in wipefile src/shred.c:1175
    coreutils#3 0x406b84 in main src/shred.c:1316
    coreutils#4 0x7f3454a1ef9f in __libc_start_main (/lib64/libc.so.6+0x1ff9f)
    coreutils#5 0x4025d8 (/tmp/coreutils-8.23/src/shred+0x4025d8)
  0x000000416628 is located 56 bytes to the left of
  global variable '*.LC49' from 'src/shred.c' (0x416660) of size 17
  0x000000416628 is located 12 bytes to the right of
  global variable 'patterns' from 'src/shred.c' (0x416540) of size 220
  SUMMARY: AddressSanitizer: global-buffer-overflow src/shred.c:782

* src/shred.c (gen_patterns): Restrict pattern selection
to the K available, which regressed due to v5.92-1462-g65533e1.
* tests/misc/shred-passes.sh: Add a deterministic test case.
* NEWS: Mention the bug fix.
Fixes http://bugs.gnu.org/20998
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants