diff --git a/LICENSE b/LICENSE index b8b44d3681..da939845db 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,5 @@ -Copyright (c) 2009-2010, Joshua Haberman -Copyright (c) 2009-2010, Google Inc. +Copyright (c) 2009-2011, Google Inc. All rights reserved. Redistribution and use in source and binary forms, with or without @@ -11,17 +10,17 @@ modification, are permitted provided that the following conditions are met: * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Joshua Haberman nor the names of any other + * Neither the name of Google Inc. nor the names of any other contributors may be used to endorse or promote products derived from this software without specific prior written permission. -THIS SOFTWARE IS PROVIDED BY JOSHUA HABERMAN ``AS IS'' AND ANY -EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL JOSHUA HABERMAN BE LIABLE FOR ANY -DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +THIS SOFTWARE IS PROVIDED BY GOOGLE INC. ``AS IS'' AND ANY EXPRESS OR IMPLIED +WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +EVENT SHALL GOOGLE INC. BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR +BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER +IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/README b/README index a241946242..0aa4817bdf 100644 --- a/README +++ b/README @@ -36,6 +36,5 @@ the major things that are broken or not yet implemented yet: CONTACT ======= -Author: Joshua Haberman (jhaberman@gmail.com, haberman@google.com) +Author: Josh Haberman (jhaberman@gmail.com, haberman@google.com) See LICENSE for copyright information. - diff --git a/lang_ext/lua/upb.c b/lang_ext/lua/upb.c index aa5f4a1354..cc21922794 100644 --- a/lang_ext/lua/upb.c +++ b/lang_ext/lua/upb.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * A Lua extension for upb. */ diff --git a/lang_ext/python/cext.c b/lang_ext/python/cext.c index c2199c46b2..59e834625a 100644 --- a/lang_ext/python/cext.c +++ b/lang_ext/python/cext.c @@ -1,8 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. - * + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "cext.h" diff --git a/lang_ext/python/cext.h b/lang_ext/python/cext.h index e0e7832edb..f53e6e7eb4 100644 --- a/lang_ext/python/cext.h +++ b/lang_ext/python/cext.h @@ -2,7 +2,7 @@ * upb - a minimalist implementation of protocol buffers. * * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. - * + * Author: Josh Haberman */ #ifndef UPB_PYTHON_CEXT_H_ diff --git a/lang_ext/python/definition.c b/lang_ext/python/definition.c index cc1089da9c..8e8b8523b3 100644 --- a/lang_ext/python/definition.c +++ b/lang_ext/python/definition.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * This file defines the Python module upb.definition. This module * defines the following Python classes, which wrap upb's internal diff --git a/lang_ext/python/definition.h b/lang_ext/python/definition.h index 040019d7ff..f7162cf384 100644 --- a/lang_ext/python/definition.h +++ b/lang_ext/python/definition.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * See def.h for a general description. These definitions * must be shared so that specific Python message types (for the diff --git a/lang_ext/python/pb.c b/lang_ext/python/pb.c index 0e04a6be1a..70d32d7cc0 100644 --- a/lang_ext/python/pb.c +++ b/lang_ext/python/pb.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * This file implements an interface to Python that is compatible * (as much as possible) with proto1 (the first implementation of diff --git a/src/upb.c b/src/upb.c index fdf5c072d1..b80de29217 100644 --- a/src/upb.c +++ b/src/upb.c @@ -1,8 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. - * + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include diff --git a/src/upb.h b/src/upb.h index 01de8cf2e3..5dfd65e8a8 100644 --- a/src/upb.h +++ b/src/upb.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * This file contains shared definitions that are widely used across upb. */ diff --git a/src/upb_atomic.h b/src/upb_atomic.h index 87d06febe1..b1ba60d62c 100644 --- a/src/upb_atomic.h +++ b/src/upb_atomic.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * Only a very small part of upb is thread-safe. Notably, individual * messages, arrays, and strings are *not* thread safe for mutating. diff --git a/src/upb_decoder.c b/src/upb_decoder.c index 6fa37b4d33..a3d00bb573 100644 --- a/src/upb_decoder.c +++ b/src/upb_decoder.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2008-2011 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2008-2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include diff --git a/src/upb_decoder.h b/src/upb_decoder.h index af2124c368..32a989a618 100644 --- a/src/upb_decoder.h +++ b/src/upb_decoder.h @@ -1,6 +1,9 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2009-2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * upb_decoder implements a high performance, streaming decoder for protobuf * data that works by implementing upb_src and getting its data from a * upb_bytesrc. @@ -9,8 +12,6 @@ * if the bytesrc returns UPB_STATUS_TRYAGAIN it is not possible to resume the * decoder when data becomes available again. Support for this could be added, * but it would add complexity and perhaps cost efficiency also. - * - * Copyright (c) 2009-2010 Joshua Haberman. See LICENSE for details. */ #ifndef UPB_DECODER_H_ diff --git a/src/upb_def.c b/src/upb_def.c index 08e5a8ce1e..059edd66cb 100644 --- a/src/upb_def.c +++ b/src/upb_def.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2008-2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2008-2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include diff --git a/src/upb_def.h b/src/upb_def.h index 9950c86326..e19aeba992 100644 --- a/src/upb_def.h +++ b/src/upb_def.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009-2011 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009-2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * Provides a mechanism for loading proto definitions from descriptors, and * data structures to represent those definitions. These form the protobuf diff --git a/src/upb_encoder.c b/src/upb_encoder.c index 304a42332a..139dc88a53 100644 --- a/src/upb_encoder.c +++ b/src/upb_encoder.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "upb_encoder.h" diff --git a/src/upb_encoder.h b/src/upb_encoder.h index d8d4b4fce3..64c5047129 100644 --- a/src/upb_encoder.h +++ b/src/upb_encoder.h @@ -1,13 +1,15 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Implements a upb_sink that writes protobuf data to the binary wire format. + * Copyright (c) 2009-2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * + * Implements a set of upb_handlers that write protobuf data to the binary wire + * format. * * For messages that have any submessages, the encoder needs a buffer * containing the submessage sizes, so they can be properly written at the * front of each message. Note that groups do *not* have this requirement. - * - * Copyright (c) 2009-2010 Joshua Haberman. See LICENSE for details. */ #ifndef UPB_ENCODER_H_ diff --git a/src/upb_glue.c b/src/upb_glue.c index 8194d4a1a9..41f974b6a0 100644 --- a/src/upb_glue.c +++ b/src/upb_glue.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "upb_glue.h" diff --git a/src/upb_glue.h b/src/upb_glue.h index afb7b59ce3..d1a26d11cd 100644 --- a/src/upb_glue.h +++ b/src/upb_glue.h @@ -1,6 +1,9 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * upb's core components like upb_decoder and upb_msg are carefully designed to * avoid depending on each other for maximum orthogonality. In other words, * you can use a upb_decoder to decode into *any* kind of structure; upb_msg is @@ -18,8 +21,6 @@ * time these functions are called. For this reason, if you are parsing lots * of data and efficiency is an issue, these may not be the best functions to * use (though they are useful for prototyping, before optimizing). - * - * Copyright (c) 2011 Joshua Haberman. See LICENSE for details. */ #ifndef UPB_GLUE_H diff --git a/src/upb_msg.c b/src/upb_msg.c index a9167e8eb4..1705b35cd8 100644 --- a/src/upb_msg.c +++ b/src/upb_msg.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * Data structure for storing a message of protobuf data. */ diff --git a/src/upb_msg.h b/src/upb_msg.h index 4895c4bf19..6785131cae 100644 --- a/src/upb_msg.h +++ b/src/upb_msg.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010-2011 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010-2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * Data structure for storing a message of protobuf data. Unlike Google's * protobuf, upb_msg and upb_array are reference counted instead of having diff --git a/src/upb_stdio.c b/src/upb_stdio.c index b4f2fce307..c84d52aae8 100644 --- a/src/upb_stdio.c +++ b/src/upb_stdio.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "upb_stdio.h" diff --git a/src/upb_stdio.h b/src/upb_stdio.h index fd71fddd9e..ba5fe1ae5d 100644 --- a/src/upb_stdio.h +++ b/src/upb_stdio.h @@ -1,10 +1,11 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * This file provides upb_bytesrc and upb_bytesink implementations for * ANSI C stdio. - * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. */ #include diff --git a/src/upb_stream.c b/src/upb_stream.c index 3634d5d1a6..af266dc2b8 100644 --- a/src/upb_stream.c +++ b/src/upb_stream.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2011 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include diff --git a/src/upb_stream.h b/src/upb_stream.h index 9221a6bdb6..f2ae11c828 100644 --- a/src/upb_stream.h +++ b/src/upb_stream.h @@ -1,6 +1,9 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2010-2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * This file defines general-purpose streaming data interfaces: * * - upb_handlers: represents a set of callbacks, very much like in XML's SAX @@ -20,9 +23,6 @@ * with input that came from protobuf binary format, protobuf text format, or * even an in-memory upb_msg -- the pretty printer will not know the * difference. - * - * Copyright (c) 2010-2011 Joshua Haberman. See LICENSE for details. - * */ #ifndef UPB_STREAM_H diff --git a/src/upb_string.c b/src/upb_string.c index cbc341448d..de633bcdbc 100644 --- a/src/upb_string.c +++ b/src/upb_string.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "upb_string.h" diff --git a/src/upb_string.h b/src/upb_string.h index 38c3d55f86..88a513f8ca 100644 --- a/src/upb_string.h +++ b/src/upb_string.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * This file defines a simple string type which is length-delimited instead * of NULL-terminated, and which has useful sharing semantics. diff --git a/src/upb_strstream.c b/src/upb_strstream.c index 8ef98846fd..37b51799eb 100644 --- a/src/upb_strstream.c +++ b/src/upb_strstream.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2010 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "upb_strstream.h" diff --git a/src/upb_strstream.h b/src/upb_strstream.h index cd8ff01d30..8da539317d 100644 --- a/src/upb_strstream.h +++ b/src/upb_strstream.h @@ -1,10 +1,11 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2009-2010 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * This file contains upb_bytesrc and upb_bytesink implementations for * upb_string. - * - * Copyright (c) 2009-2010 Joshua Haberman. See LICENSE for details. */ #ifndef UPB_STRSTREAM_H diff --git a/src/upb_table.c b/src/upb_table.c index 54af32d512..b9b9824f99 100644 --- a/src/upb_table.c +++ b/src/upb_table.c @@ -1,9 +1,11 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * There are a few printf's strewn throughout this file, uncommenting them * can be useful for debugging. - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. */ #include "upb_table.h" diff --git a/src/upb_table.h b/src/upb_table.h index a799653c34..9b53a372c6 100644 --- a/src/upb_table.h +++ b/src/upb_table.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * * This file defines very fast int->struct (inttable) and string->struct * (strtable) hash tables. The struct can be of any size, and it is stored diff --git a/src/upb_textprinter.c b/src/upb_textprinter.c index 6f123d6ffa..948d28cbda 100644 --- a/src/upb_textprinter.c +++ b/src/upb_textprinter.c @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #include "upb_textprinter.h" diff --git a/src/upb_textprinter.h b/src/upb_textprinter.h index 40f392be07..aa9febb85c 100644 --- a/src/upb_textprinter.h +++ b/src/upb_textprinter.h @@ -1,7 +1,8 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman */ #ifndef UPB_TEXT_H_ diff --git a/src/upb_varint_decoder.h b/src/upb_varint_decoder.h index 86195966cd..6d880223bf 100644 --- a/src/upb_varint_decoder.h +++ b/src/upb_varint_decoder.h @@ -1,13 +1,14 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2011 Google Inc. See LICENSE for details. + * Author: Josh Haberman + * * A number of routines for varint decoding (we keep them all around to have * multiple approaches available for benchmarking). All of these functions * require the buffer to have at least 10 bytes available; if we don't know * for sure that there are 10 bytes, then there is only one viable option * (branching on every byte). - * - * Copyright (c) 2011 Joshua Haberman. See LICENSE for details. */ #ifndef UPB_VARINT_DECODER_H_ diff --git a/src/upbc.c b/src/upbc.c index 4fa8a71954..956a1b22e4 100644 --- a/src/upbc.c +++ b/src/upbc.c @@ -1,11 +1,12 @@ /* * upb - a minimalist implementation of protocol buffers. * - * upbc is the upb compiler. This is some deep code that I wish could be - * easier to understand, but by its nature it is doing some very "meta" - * kinds of things. + * Copyright (c) 2009 Google Inc. See LICENSE for details. + * Author: Josh Haberman * - * Copyright (c) 2009 Joshua Haberman. See LICENSE for details. + * upbc is the upb compiler, which at the moment simply takes a + * protocol descriptor and outputs a header file containing the + * names and types of the fields. */ #include diff --git a/tests/test_varint.c b/tests/test_varint.c index 0150c06354..ef74fa6ee7 100644 --- a/tests/test_varint.c +++ b/tests/test_varint.c @@ -1,7 +1,7 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2011 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2011 Google Inc. See LICENSE for details. */ #include "upb_varint_decoder.h" diff --git a/tests/test_vs_proto2.cc b/tests/test_vs_proto2.cc index f3c54b41f1..86d21d2edc 100644 --- a/tests/test_vs_proto2.cc +++ b/tests/test_vs_proto2.cc @@ -1,10 +1,10 @@ /* * upb - a minimalist implementation of protocol buffers. * + * Copyright (c) 2011 Google Inc. See LICENSE for details. + * * A test that verifies that our results are identical to proto2 for a * given proto type and input protobuf. - * - * Copyright (c) 2011 Joshua Haberman. See LICENSE for details. */ #include diff --git a/tests/upb_test.h b/tests/upb_test.h index 0e307c5889..3009a4058d 100644 --- a/tests/upb_test.h +++ b/tests/upb_test.h @@ -1,7 +1,7 @@ /* * upb - a minimalist implementation of protocol buffers. * - * Copyright (c) 2011 Joshua Haberman. See LICENSE for details. + * Copyright (c) 2011 Google Inc. See LICENSE for details. */ #ifndef UPB_TEST_H_