Giter Site home page Giter Site logo

Issue in replace exising object about parson HOT 2 CLOSED

kgabis avatar kgabis commented on August 21, 2024
Issue in replace exising object

from parson.

Comments (2)

kgabis avatar kgabis commented on August 21, 2024

I wasn't able to reproduce this issue. That's the code I used:

#include <assert.h>
#include "parson.h"

int main()
{
    JSON_Value *file1_value = json_parse_file("1.json"); /* http://pastebin.com/X5tjG9hd */
    assert(file1_value != NULL);

    JSON_Object *root_object = json_value_get_object(file1_value);
    assert(root_object != NULL);

    JSON_Object *protection = json_object_get_object(root_object, "protection");
    assert(protection != NULL);

    JSON_Value *file2_value = json_parse_file("2.json"); /* http://pastebin.com/W2YnuXsj */
    assert(file2_value != NULL);

    JSON_Status status = json_object_set_value(protection, "macs", file2_value); 
    assert(status == JSONSuccess);

    char* result = json_serialize_to_string(file1_value);
    assert(result != NULL);

    puts(result);
}

Could you include full example that shows this issue?

from parson.

pokevas avatar pokevas commented on August 21, 2024

Yeah, it is my error.
I have write function and found error in my code. Sorry for false Issue.
Closed.

from parson.

Related Issues (20)

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.