amiws 2.2.1
Loading...
Searching...
No Matches
amipack_parser_prompt.c File Reference

AMI (Asterisk Management Interface) prompt packet parser. More...

#include "amipack.h"
Include dependency graph for amipack_parser_prompt.c:

Enumerations

enum  yycond_prompt { yycinit , yycminor , yycpatch , yycmajor }
 

Functions

int amipack_parser_prompt (const char *packet, AMIVer *ver)
 

Detailed Description

AMI (Asterisk Management Interface) prompt packet parser.

amiws – Library with functions for read/create AMI packets Copyright (C) 2016, Stas Kobzar stask.nosp@m.obza.nosp@m.r@mod.nosp@m.ulis.nosp@m..ca

This file is part of amiws.

amiws is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

amiws is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with amiws. If not, see http://www.gnu.org/licenses/.

Author
Stas Kobzar stas..nosp@m.kobz.nosp@m.ar@mo.nosp@m.duli.nosp@m.s.ca

Enumeration Type Documentation

◆ yycond_prompt

re2c condition markers

Function Documentation

◆ amipack_parser_prompt()

int amipack_parser_prompt ( const char * packet,
AMIVer * version )

Parse AMI protocol prompt string when user logged in. Will set AMIver structure with parsed server AMI version. Prompt header example: Asterisk Call Manager/1.1

Parameters
packetPacket received from server as bytes array.
versionAMIVer struct will be set when packet parsed
Returns
1 on success or 0 on fail