All of lore.kernel.org
 help / color / mirror / Atom feed
* "alsatplg -v 1 -o -"  silently corrupts output
       [not found] <1640335526728811026-webhooks-bot@alsa-project.org>
@ 2021-12-24  8:45 ` GitHub issues - opened
  0 siblings, 0 replies; only message in thread
From: GitHub issues - opened @ 2021-12-24  8:45 UTC (permalink / raw)
  To: alsa-devel

alsa-project/alsa-utils issue #131 was opened from marc-hb:

`alsatplg -v 1` works.
`alsatplg -o -` works too.

Using both produces silently a binary .tplg file prefixed with debug logs:

```
B0x003d3b/015675 - pcm 'DMIC': write 912 bytes
B0x0040cb/016587 - pcm 'HDMI1': write 912 bytes
B0x00445b/017499 - pcm 'HDMI2': write 912 bytes
B0x0047eb/018411 - pcm 'HDMI3': write 912 bytes
B0x004b7b/019323 - pcm 'DMIC16kHz': write 912 bytes
B0x004f0b/020235 - block size for type be (11:10) is 0x2ad4/10964
B0x004f0b/020235 - header index 0CoSA^E^@^@^@^@^@^@^@^H^@^@^@$^@^@
^@^@^@^@^@s^@^@^@^@^@^@^@^A^@^@^@p^@^@^@ ^@^@^@.^@^@^@ ^@^@^@^F^@^
@^@^F^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^
@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^
@^@^@^@^@^@^@^@^@^...
```

I would have expected alsatplg -v to use stderr, this would have avoided this problem. Probably too late by now.

I suggest simply failing with an error message when both options are used at the same time. Any other solution that does not silently produces corrupted output would be a huge improvement.

Context: thesofproject/sof/pull/5132

Issue URL     : https://github.com/alsa-project/alsa-utils/issues/131
Repository URL: https://github.com/alsa-project/alsa-utils

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-12-24  8:46 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1640335526728811026-webhooks-bot@alsa-project.org>
2021-12-24  8:45 ` "alsatplg -v 1 -o -" silently corrupts output GitHub issues - opened

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.