GithubHelp home page GithubHelp logo

lloydlabs / librini Goto Github PK

View Code? Open in Web Editor NEW
28.0 28.0 4.0 18 KB

Rini is a tiny, non-libc dependant, .ini file parser programmed from scratch in C99.

License: MIT License

CMake 1.28% C 98.72%
c embedded embedded-c ini-parser parse parser tiny

librini's People

Contributors

lloydlabs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

librini's Issues

Fix two's compliment

We need to fix the two's compliment which occurs within the rini_signed_int_str, for some reason, when unit tests were being taken this was returning 0 on some cases.

Integer values are parsed incorrectly

Description

Integer values are parsed incorrectly: the first digit of the value is always flipped to the number '1', for instance, this

ssh_port=99

Would be parsed as '19' instead of '99'. I've tried with a few different numbers of different lengths and it seems to always be the first digit which gets changed to be a "1".

I'm quite happy to look at this and submit a PR if you don't have time to investigate it.

Reproduction Steps

  1. Compile the library
  2. Link it into the server_config.c file in the examples directory of this repository.
  3. Run the executable

Expected

Name of main server: honeypot
Please change the port from 99 to a number above 1024

Actual

Name of main server: honeypot
Please change the port from 19 to a number above 1024

Environment

OS: Fedora 26
Kernel version: 4.13.4-200.fc26.x86_64
Compiled with clang 4.0.1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.