mirror of
https://github.com/systemd/systemd.git
synced 2024-11-08 11:27:32 +03:00
ata_id: fix identify string fixup
This commit is contained in:
parent
09db3f5b66
commit
2b2823b4b5
@ -307,8 +307,8 @@ static void disk_identify_get_string(uint8_t identify[512],
|
|||||||
assert((dest_len & 1) == 0);
|
assert((dest_len & 1) == 0);
|
||||||
|
|
||||||
while (dest_len > 0) {
|
while (dest_len > 0) {
|
||||||
c1 = ((uint16_t *) identify)[offset_words] >> 8;
|
c1 = identify[offset_words * 2 + 1];
|
||||||
c2 = ((uint16_t *) identify)[offset_words] & 0xff;
|
c2 = identify[offset_words * 2];
|
||||||
*dest = c1;
|
*dest = c1;
|
||||||
dest++;
|
dest++;
|
||||||
*dest = c2;
|
*dest = c2;
|
||||||
|
Loading…
Reference in New Issue
Block a user