File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -2827,7 +2827,7 @@ fn display_item_long(
28272827 // TODO: See how Mac should work here
28282828 let is_acl_set = false ;
28292829 #[ cfg( all( unix, not( any( target_os = "android" , target_os = "macos" ) ) ) ) ]
2830- let is_acl_set = has_acl ( item. display_name ( ) ) ;
2830+ let is_acl_set = has_acl ( item. path ( ) ) ;
28312831 output_display. extend ( display_permissions ( md, true ) . as_bytes ( ) ) ;
28322832 if item. security_context ( config) . len ( ) > 1 {
28332833 // GNU `ls` uses a "." character to indicate a file with a security context,
Original file line number Diff line number Diff line change @@ -5762,6 +5762,15 @@ fn test_acl_display() {
57625762 . succeeds ( )
57635763 . stdout_matches ( & re_with_acl)
57645764 . stdout_matches ( & re_without_acl) ;
5765+
5766+ // Verify that it also works if the current dir is different from the ucmd temporary dir
5767+ scene
5768+ . ucmd ( )
5769+ . current_dir ( "/" )
5770+ . args ( & [ "-la" , & at. as_string ( ) ] )
5771+ . succeeds ( )
5772+ . stdout_matches ( & re_with_acl)
5773+ . stdout_matches ( & re_without_acl) ;
57655774}
57665775
57675776// Make sure that "ls --color" correctly applies color "normal" to text and
You can’t perform that action at this time.
0 commit comments