avdtp_initiator.c (2fca4dad957cd7b88f4657ed51e89c12615dda72) | avdtp_initiator.c (b93f89661ecd1d19be40311be96b92932960a800) |
---|---|
1/* 2 * Copyright (C) 2016 BlueKitchen GmbH 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 8 * 1. Redistributions of source code must retain the above copyright --- 224 unchanged lines hidden (view full) --- 233 log_error("AVDTP_SI_CLOSE: stream endpoint is null"); 234 break; 235 } 236 switch (stream_endpoint->state){ 237 case AVDTP_STREAM_ENDPOINT_OPENED: 238 case AVDTP_STREAM_ENDPOINT_STREAMING: 239 stream_endpoint_for_event = stream_endpoint; 240 stream_endpoint->state = AVDTP_STREAM_ENDPOINT_CLOSING; | 1/* 2 * Copyright (C) 2016 BlueKitchen GmbH 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 8 * 1. Redistributions of source code must retain the above copyright --- 224 unchanged lines hidden (view full) --- 233 log_error("AVDTP_SI_CLOSE: stream endpoint is null"); 234 break; 235 } 236 switch (stream_endpoint->state){ 237 case AVDTP_STREAM_ENDPOINT_OPENED: 238 case AVDTP_STREAM_ENDPOINT_STREAMING: 239 stream_endpoint_for_event = stream_endpoint; 240 stream_endpoint->state = AVDTP_STREAM_ENDPOINT_CLOSING; |
241 l2cap_disconnect(stream_endpoint->l2cap_media_cid, 0); | 241 l2cap_disconnect(stream_endpoint->l2cap_media_cid); |
242 break; 243 default: 244 break; 245 } 246 break; 247 case AVDTP_SI_ABORT: 248 if (!stream_endpoint){ 249 log_error("AVDTP_SI_ABORT: stream endpoint is null"); 250 break; 251 } 252 switch (stream_endpoint->state){ 253 case AVDTP_STREAM_ENDPOINT_CONFIGURED: 254 case AVDTP_STREAM_ENDPOINT_CLOSING: 255 case AVDTP_STREAM_ENDPOINT_OPENED: 256 case AVDTP_STREAM_ENDPOINT_STREAMING: 257 stream_endpoint_for_event = stream_endpoint; 258 stream_endpoint->state = AVDTP_STREAM_ENDPOINT_ABORTING; | 242 break; 243 default: 244 break; 245 } 246 break; 247 case AVDTP_SI_ABORT: 248 if (!stream_endpoint){ 249 log_error("AVDTP_SI_ABORT: stream endpoint is null"); 250 break; 251 } 252 switch (stream_endpoint->state){ 253 case AVDTP_STREAM_ENDPOINT_CONFIGURED: 254 case AVDTP_STREAM_ENDPOINT_CLOSING: 255 case AVDTP_STREAM_ENDPOINT_OPENED: 256 case AVDTP_STREAM_ENDPOINT_STREAMING: 257 stream_endpoint_for_event = stream_endpoint; 258 stream_endpoint->state = AVDTP_STREAM_ENDPOINT_ABORTING; |
259 l2cap_disconnect(stream_endpoint->l2cap_media_cid, 0); | 259 l2cap_disconnect(stream_endpoint->l2cap_media_cid); |
260 break; 261 default: 262 break; 263 } 264 break; 265 266 case AVDTP_SI_DELAYREPORT: 267 break; --- 226 unchanged lines hidden --- | 260 break; 261 default: 262 break; 263 } 264 break; 265 266 case AVDTP_SI_DELAYREPORT: 267 break; --- 226 unchanged lines hidden --- |