Questions tagged [nul]

NUL is the abbreviation for the null character in several character sets

NUL has a value of 0 and is often written as the escape sequence \0. It is used as a terminator in standard strings.

179 questions
0
votes
1 answer

Accessing Arraylist from bind service returning empty

I am accessing marraylist variable of service and although it is initialized by data from Firebase but returning empty marraylist in Activity this variable is initialized in service array by fetching data from Firebase database and in toast I am…
0
votes
1 answer

Grep with redirect is giving null byte

My grep command is generating a NUL byte at the end of its output. I have file.xml which contains only: Now running grep -Pzo '(\n|.)*?()' gives the expected output:
0
votes
2 answers

How to specify NUL-terminated names of files for wc --files0-from=F

I need to test wc with --files0-from=F flag, but I don't know how to write a file that contains NUL-terminated file names? Whatever I try, it merges the file names together and outputs: wc: '1.txt2.txt': No such file or directory wc: '1.txt…
ivanacorovic
  • 2,669
  • 4
  • 30
  • 46
0
votes
2 answers

How to write NUL to all log files in a folder using windows command line

I have multiple log files that start as ABC_.log in a windows environment. I want to clean that file (like writing /dev/null to file in linux). I need to do it through command line. What I tried: cmd:$ break > ABC_*.log and cmd:$ type NUL >…
TheBeginner
  • 405
  • 5
  • 23
0
votes
2 answers

Differentiating between embedded NUL and NUL-terminator

I have a const char* pointing to data in hex format, I need to find the length of the data for that I am checking for NUL-terminator but when \x00 comes up it detects it as NUL-terminator returning incorrect length. How can I get around that? const…
Aamir Shaikh
  • 345
  • 1
  • 2
  • 13
0
votes
0 answers

c# Equality operators on null type

on the c# 6.0 tutorial it says: Lifted equality operators handle nulls just like reference types do. This means two null values are equal: Console.WriteLine ( null == null); // True Console.WriteLine((bool?)null == (bool?)null); // True While I…
Huibin Zhang
  • 1,072
  • 1
  • 15
  • 30
0
votes
2 answers

Can't assign a new object to pointer pointer type in cpp

Assigning a new object to a pointer pointer type in cpp crushes the program. Code looks like this: #include using namespace std; struct Node{ int key; Node * nex; }; int main(){ Node * my_node = new Node; Node ** pp_node; …
CerushDope
  • 445
  • 1
  • 5
  • 14
0
votes
1 answer

Is there a need to check whether the current reference is null?

I've learned that inside a non-static block, this represents the current reference on which that block is invoked. My doubt is is there any need of checking this is ever null or not, I mean if it is null in the first place the block(method,…
Arun Sudhakaran
  • 2,167
  • 4
  • 27
  • 52
0
votes
1 answer

XML Val Error Source of issue How to proceed

I am working in a Assessment trying to learn XML But when I valisdate it I get this 19: 30 Element type "Name" must not be declared more than once. 20: 33 Element type "Company" must not be declared more than once. 21: 38 Element type…
EddieLost
  • 3
  • 1
0
votes
1 answer

malloc and strcpy interactions

I've been testing out interactions between malloc() and various string functions in order to try to learn more about how pointers and memory work in C, but I'm a bit confused about the following interactions. char *myString = malloc(5); // enough…
Prism
  • 53
  • 1
  • 4
0
votes
1 answer

Why do I have NUL line in my written file using fopen fclose c++ linux?

I have some C code running on a linux OS into a portable device. I'm using a VRmagic system, similar to BeagleBone etc...). In this code, I'm using the following function to write results inside a txt file. //globale definition FILE *logfile; const…
Bobby
  • 43
  • 2
0
votes
1 answer

automappewr map null value to destination if source value is zero

Im mapping from a dto to a view model. The dto has a double property, if this value is zero I want to map it as null (this stops infragistics graph plotting a point in case of null, so nothing gets displayed ) I have this but it doesnt work I need…
proteus
  • 545
  • 2
  • 12
  • 36
0
votes
1 answer

Why won't copy paste work when NUL character is present in datagridview selection?

Why will any form of copy/paste of datagridview not work if there are "NUL" characters (i.e. ASCII code = 0) present? If there are "NUL" characters present in data, the datagridview displays them as spaces but will not copy (or at least, not…
0
votes
1 answer

Converting null value to 0 for all fields in MS access

I have a monthly sales table for different customers in ACCESS. The field names are in order Sales_201601, Sales_201602 etc. which changes dynamically with every data refresh. I am looking for a SQL query which can automatically pick all columns…
Bi1207
  • 21
  • 7
0
votes
1 answer

Using sed to fix pdf files

I am running GNU sed version 4.2.1 on windows. I have a huge number of PDF files having %%EOF + newline + a lot of NUL chars in the last record. See hexdump below. 0000b890: 25 25 45 4F 46 0D 0A 00 - 00 00 00 00 00 00 00 00 |%%EOF …