Add missing newline to avrorouter output
The schema was not terminated with a newline.
This commit is contained in:
		@ -848,13 +848,15 @@ GWBUF* read_avro_json_schema(const char *avrofile, const char* dir)
 | 
				
			|||||||
        if (file)
 | 
					        if (file)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            int nread;
 | 
					            int nread;
 | 
				
			||||||
            while ((nread = fread(buffer, 1, sizeof(buffer), file)) > 0)
 | 
					            while ((nread = fread(buffer, 1, sizeof(buffer) - 1, file)) > 0)
 | 
				
			||||||
            {
 | 
					            {
 | 
				
			||||||
                while (isspace(buffer[nread - 1]))
 | 
					                while (isspace(buffer[nread - 1]))
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
                    nread--;
 | 
					                    nread--;
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					                buffer[nread++] = '\n';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                GWBUF * newbuf = gwbuf_alloc_and_load(nread, buffer);
 | 
					                GWBUF * newbuf = gwbuf_alloc_and_load(nread, buffer);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                if (newbuf)
 | 
					                if (newbuf)
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user