This file is indexed.

/usr/share/doc/libjansson-doc/html/upgrading.html is in libjansson-doc 2.9-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Upgrading from 1.x &#8212; Jansson 2.9-dev documentation</title>
    
    <link rel="stylesheet" href="_static/alabaster.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    './',
        VERSION:     '2.9-dev',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <link rel="index" title="Index" href="genindex.html" />
    <link rel="search" title="Search" href="search.html" />
    <link rel="top" title="Jansson 2.9-dev documentation" href="index.html" />
    <link rel="next" title="Tutorial" href="tutorial.html" />
    <link rel="prev" title="Getting Started" href="gettingstarted.html" />
   
  <link rel="stylesheet" href="_static/custom.css" type="text/css" />
  
  <meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9" />

  </head>
  <body role="document">
  

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body" role="main">
            
  <div class="section" id="upgrading-from-1-x">
<h1>Upgrading from 1.x<a class="headerlink" href="#upgrading-from-1-x" title="Permalink to this headline"></a></h1>
<p>This chapter lists the backwards incompatible changes introduced in
Jansson 2.0, and the steps that are needed for upgrading your code.</p>
<p><strong>The incompatibilities are not dramatic.</strong> The biggest change is that
all decoding functions now require and extra parameter. Most programs
can be modified to work with 2.0 by adding a <code class="docutils literal"><span class="pre">0</span></code> as the second
parameter to all calls of <a class="reference internal" href="apiref.html#c.json_loads" title="json_loads"><code class="xref c c-func docutils literal"><span class="pre">json_loads()</span></code></a>, <a class="reference internal" href="apiref.html#c.json_loadf" title="json_loadf"><code class="xref c c-func docutils literal"><span class="pre">json_loadf()</span></code></a>
and <a class="reference internal" href="apiref.html#c.json_load_file" title="json_load_file"><code class="xref c c-func docutils literal"><span class="pre">json_load_file()</span></code></a>.</p>
<div class="section" id="compatibility">
<h2>Compatibility<a class="headerlink" href="#compatibility" title="Permalink to this headline"></a></h2>
<p>Jansson 2.0 is backwards incompatible with the Jansson 1.x releases.
It is ABI incompatible, i.e. all programs dynamically linking to the
Jansson library need to be recompiled. It&#8217;s also API incompatible,
i.e. the source code of programs using Jansson 1.x may need
modifications to make them compile against Jansson 2.0.</p>
<p>All the 2.x releases are guaranteed to be backwards compatible for
both ABI and API, so no recompilation or source changes are needed
when upgrading from 2.x to 2.y.</p>
</div>
<div class="section" id="list-of-incompatible-changes">
<h2>List of Incompatible Changes<a class="headerlink" href="#list-of-incompatible-changes" title="Permalink to this headline"></a></h2>
<dl class="docutils">
<dt><strong>Decoding flags</strong></dt>
<dd><p class="first">For future needs, a <code class="docutils literal"><span class="pre">flags</span></code> parameter was added as the second
parameter to all decoding functions, i.e. <a class="reference internal" href="apiref.html#c.json_loads" title="json_loads"><code class="xref c c-func docutils literal"><span class="pre">json_loads()</span></code></a>,
<a class="reference internal" href="apiref.html#c.json_loadf" title="json_loadf"><code class="xref c c-func docutils literal"><span class="pre">json_loadf()</span></code></a> and <a class="reference internal" href="apiref.html#c.json_load_file" title="json_load_file"><code class="xref c c-func docutils literal"><span class="pre">json_load_file()</span></code></a>. All calls to
these functions need to be changed by adding a <code class="docutils literal"><span class="pre">0</span></code> as the second
argument. For example:</p>
<div class="last highlight-c"><div class="highlight"><pre><span></span><span class="cm">/* old code */</span>
<span class="n">json_loads</span><span class="p">(</span><span class="n">input</span><span class="p">,</span> <span class="o">&amp;</span><span class="n">error</span><span class="p">);</span>

<span class="cm">/* new code */</span>
<span class="n">json_loads</span><span class="p">(</span><span class="n">input</span><span class="p">,</span> <span class="mi">0</span><span class="p">,</span> <span class="o">&amp;</span><span class="n">error</span><span class="p">);</span>
</pre></div>
</div>
</dd>
<dt><strong>Underlying type of JSON integers</strong></dt>
<dd><p class="first">The underlying C type of JSON integers has been changed from
<code class="xref c c-type docutils literal"><span class="pre">int</span></code> to the widest available signed integer type, i.e.
<code class="xref c c-type docutils literal"><span class="pre">long</span> <span class="pre">long</span></code> or <code class="xref c c-type docutils literal"><span class="pre">long</span></code>, depending on whether
<code class="xref c c-type docutils literal"><span class="pre">long</span> <span class="pre">long</span></code> is supported on your system or not. This makes
the whole 64-bit integer range available on most modern systems.</p>
<p class="last"><code class="docutils literal"><span class="pre">jansson.h</span></code> has a typedef <a class="reference internal" href="apiref.html#c.json_int_t" title="json_int_t"><code class="xref c c-type docutils literal"><span class="pre">json_int_t</span></code></a> to the underlying
integer type. <code class="xref c c-type docutils literal"><span class="pre">int</span></code> should still be used in most cases when
dealing with smallish JSON integers, as the compiler handles
implicit type coercion. Only when the full 64-bit range is needed,
<a class="reference internal" href="apiref.html#c.json_int_t" title="json_int_t"><code class="xref c c-type docutils literal"><span class="pre">json_int_t</span></code></a> should be explicitly used.</p>
</dd>
<dt><strong>Maximum encoder indentation depth</strong></dt>
<dd>The maximum argument of the <code class="docutils literal"><span class="pre">JSON_INDENT()</span></code> macro has been
changed from 255 to 31, to free up bits from the <code class="docutils literal"><span class="pre">flags</span></code>
parameter of <a class="reference internal" href="apiref.html#c.json_dumps" title="json_dumps"><code class="xref c c-func docutils literal"><span class="pre">json_dumps()</span></code></a>, <a class="reference internal" href="apiref.html#c.json_dumpf" title="json_dumpf"><code class="xref c c-func docutils literal"><span class="pre">json_dumpf()</span></code></a> and
<a class="reference internal" href="apiref.html#c.json_dump_file" title="json_dump_file"><code class="xref c c-func docutils literal"><span class="pre">json_dump_file()</span></code></a>. If your code uses a bigger indentation
than 31, it needs to be changed.</dd>
<dt><strong>Unsigned integers in API functions</strong></dt>
<dd>Version 2.0 unifies unsigned integer usage in the API. All uses of
<code class="xref c c-type docutils literal"><span class="pre">unsigned</span> <span class="pre">int</span></code> and <code class="xref c c-type docutils literal"><span class="pre">unsigned</span> <span class="pre">long</span></code> have been replaced
with <code class="xref c c-type docutils literal"><span class="pre">size_t</span></code>. This includes flags, container sizes, etc.
This should not require source code changes, as both
<code class="xref c c-type docutils literal"><span class="pre">unsigned</span> <span class="pre">int</span></code> and <code class="xref c c-type docutils literal"><span class="pre">unsigned</span> <span class="pre">long</span></code> are usually
compatible with <code class="xref c c-type docutils literal"><span class="pre">size_t</span></code>.</dd>
</dl>
</div>
</div>


          </div>
        </div>
      </div>
      <div class="sphinxsidebar" role="navigation" aria-label="main navigation">
        <div class="sphinxsidebarwrapper">
  <h3><a href="index.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">Upgrading from 1.x</a><ul>
<li><a class="reference internal" href="#compatibility">Compatibility</a></li>
<li><a class="reference internal" href="#list-of-incompatible-changes">List of Incompatible Changes</a></li>
</ul>
</li>
</ul>
<div class="relations">
<h3>Related Topics</h3>
<ul>
  <li><a href="index.html">Documentation overview</a><ul>
      <li>Previous: <a href="gettingstarted.html" title="previous chapter">Getting Started</a></li>
      <li>Next: <a href="tutorial.html" title="next chapter">Tutorial</a></li>
  </ul></li>
</ul>
</div>
  <div role="note" aria-label="source link">
    <h3>This Page</h3>
    <ul class="this-page-menu">
      <li><a href="_sources/upgrading.txt"
            rel="nofollow">Show Source</a></li>
    </ul>
   </div>
<div id="searchbox" style="display: none" role="search">
  <h3>Quick search</h3>
    <form class="search" action="search.html" method="get">
      <div><input type="text" name="q" /></div>
      <div><input type="submit" value="Go" /></div>
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="footer">
      &copy;2009-2016, Petri Lehtinen.
      
      |
      Powered by <a href="http://sphinx-doc.org/">Sphinx 1.4.8</a>
      &amp; <a href="https://github.com/bitprophet/alabaster">Alabaster 0.7.8</a>
      
      |
      <a href="_sources/upgrading.txt"
          rel="nofollow">Page source</a>
    </div>

    

    
  </body>
</html>