-
Notifications
You must be signed in to change notification settings - Fork 8
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
airplay service cannot be discovered #5
Comments
I found that a crash occurs when adding a txt record |
Can you share your code? |
I just do some update in climdnssvc.c,this is my code:
#ifdef _WIN32
#if defined(SIGPIPE)
#ifdef _WIN32
#ifdef _WIN32
} |
when I use it with removing the first NULL element in txt, it can enter the branch,but a segfault occurred during runtime. |
I think you misunderstood the syntax of TXT. It's an array of pointers and a NULL indicates the last item. If you put NULL first, nothing will be taken into account. If you forget the NULL at the end, the parser will runaway everywhere and crash |
But it also crashed if I only placed NULL at the end. |
You either don't set a TXT at all (the txt parameter in the function call is NULL) or it includes at least one element and then finishes by NULL. You can't obviously send an array with just NULL inside, you send a NULL array instead. |
yes,I just update with this,it also crash. |
You can look at my AirConnect project and see how I'm using it |
I look the libraop project in AirConnect,it show txt code like this:https://github.com/philippe44/libraop/blob/master/src/raop_server.c |
No, I do use services w/ TXT, it would not work otherwise, AirPlay would not work. What you probably missed is that the leading NULL is replaced a few lines below by a dynamically generated string.
|
I use this library to register the airplay service, but it cannot be discovered using a Mac computer. Are there any restrictions?
The text was updated successfully, but these errors were encountered: