Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Serial device name for PTT too short (again) #335

Open
oe1rsa opened this issue May 8, 2021 · 0 comments
Open

Serial device name for PTT too short (again) #335

oe1rsa opened this issue May 8, 2021 · 0 comments

Comments

@oe1rsa
Copy link

oe1rsa commented May 8, 2021

In file audio.h the field ptt_device is reserved with 100 char's. The comment already mentions it:

/* For years, 20 characters was plenty then we start getting extreme names like this: */
/* /dev/serial/by-id/usb-FTDI_Navigator__CAT___2nd_PTT__00000000-if00-port0 */

My dev name is:

/dev/serial/by-id/usb-Silicon_Labs_CP2102_USB_to_UART_Bridge_Controller_IC-9100_04002076_A-if00-port0

This is 102 chars. Not sure what the best solution would be. One option is to include limits.h and use PATH_MAX. I am afraid this will rise portability issues. I guess the best option would be dynamic allocation (with the burden of freeing it later). I would ask if someone can make it 200 chars (or 256) at least.

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

No branches or pull requests

1 participant