mirror of
https://github.com/topjohnwu/ndk-busybox.git
synced 2024-11-25 12:49:54 +00:00
Fix a bug reported by junkio@cox.net involving the mode_chars index.
This commit is contained in:
parent
bf83355dda
commit
062913f662
@ -20,6 +20,11 @@
|
||||
*
|
||||
*/
|
||||
|
||||
/* Aug 13, 2003
|
||||
* Fix a bug reported by junkio@cox.net involving the mode_chars index.
|
||||
*/
|
||||
|
||||
|
||||
#include <assert.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
@ -119,7 +124,7 @@ const char *bb_mode_string(int mode)
|
||||
} while (++j < 3);
|
||||
++i;
|
||||
if (mode & (010000 >> i)) {
|
||||
*p = mode_chars[3 + k + (i >> 1)];
|
||||
*p = mode_chars[3 + (k & 2) + (i == 3)];
|
||||
}
|
||||
} while (i < 3);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user