Main Page | Data Structures | Directories | File List | Data Fields | Globals

ks_bparse.c File Reference

libkarmaclient's bpacket parser More...

#include "ks_config.h"
#include "ks_bparse.h"
#include "ks_assoc.h"
#include "ks_array.h"
#include "ks_string.h"
#include "ks_number.h"
#include <stdlib.h>
#include <ctype.h>
#include <stdio.h>

Go to the source code of this file.

Functions

ks_base_tks_bparse (const char *data, int len)


Detailed Description

libkarmaclient's bpacket parser

this module provides functions to parse responses from a karmaserver

Definition in file ks_bparse.c.


Function Documentation

ks_base_t* ks_bparse const char *  data,
int  len
 

Parse a response from a karmaserver. The parser is slightly generous, and accepts the following invalid case:

  • "ie" is an integer value 0.

Additionally, the following invalid case will cause a crash:

  • "dieiee" is a dictionary with a nonstring key

Parameters:
data a string containing the response packet from a karmaserver
len the length of the response packet (chars)
Returns:
a list of ks_base_t objects recovered from the packet

Definition at line 201 of file ks_bparse.c.

Referenced by ks_response_bparse().


Generated on Tue Aug 7 21:11:31 2007 for libkarmaclient by  doxygen 1.4.4