Tags down


What does 0600 mean in a function? Is it same as \200?

By : Padhu
Date : July 31 2020, 04:00 PM
I wish this helpful for you I'm trying to write the memccpy() function myself. I'll call is ft_memccpy(). I found test main functions online and there are two test functions that confuse me. The first test function works fine with my ft_memccpy() but the second test function doesn't. And I don't get it because the only difference between test1 and test2 is that \200 is changed to 0600. , Convert compare to use unsigned char.
code :
void *ft_memccpy(void *dest, const void *src, int c, size_t n) {
    unsigned char *dptr = (unsigned char *) dest;
    // better style to not cast away const-ness
    const unsigned char *sptr = (const unsigned char *) src;

    while (n && *dptr && *sptr) {
        *dptr = *sptr;
        if (*sptr == (unsigned char)c) {
            return (++dptr);
    return 0;

Share : facebook icon twitter icon

Convert 500+ files' names from Unicode U+0600 to Text

By : Sahin
Date : March 29 2020, 07:55 AM
this one helps. Due to compressing files t move from a server to another many times a huge number of images had their names changed.. from Text to Unicode U+0600 ... Which is Arabic BTW , Perhaps the following will be helpful:
code :
use strict;
use warnings;
use open qw(:std :utf8);

my $rename = 0;

for my $oldFileName (<*>) {
    my $newFileName = $oldFileName;
    $newFileName =~ s/#U([a-f0-9]+)([^#]+)?/chr( hex $1 ) . ( $2 ? $2 : '' )/gei;

    if ( $newFileName eq $oldFileName ) {
        warn "File '$oldFileName' not in convertible format!\n";

    if ( -e $newFileName ) {
        warn "File '$newFileName' already exists!\n";

    print $rename ? 'Renaming: ' : 'Testing: ';
    print "$oldFileName -> $newFileName\n";
    rename $oldFileName, $newFileName if $rename;

print "Done!\n\n";

java.time.format.DateTimeParseException: Text '2016-08-30T06:18:17:698-0600' could not be parsed at index 24

By : Derek Rhodenbaugh
Date : March 29 2020, 07:55 AM
it fixes the issue If you change your pattern to yyyy-MM-dd'T'HH:mm:ss.SSSZ it will print 2016-08-30T06:18:17.123.
But in your code, the date are with : in milliseconds when the correct is ..
code :
        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd'T'HH:mm:ss.SSSZ");
        String attDate = "2016-08-30T06:18:17.123-0600";
        //attDate = attDate.substring(0, 19);
        System.out.println("####attask date: "+attDate);
        LocalDateTime dt = LocalDateTime.parse(attDate, formatter);
####attask date: 2016-08-30T06:18:17.123-0600

How can i parse a json date to c# datetime formate with utc +0600

By : user1467705
Date : March 29 2020, 07:55 AM
around this issue You can use JsonSerializerSettings to control how the date is processed like:
code :
var jsonSerializerSettings = new JsonSerializerSettings()
     DateTimeZoneHandling = DateTimeZoneHandling.Local

var obj = JsonConvert.DeserializeObject<DateTime>(sDate, jsonSerializerSettings);

PHP session mode keeps using 0600 permissions

By : user1992964
Date : March 29 2020, 07:55 AM
Any of those help The /var/lib/php/sessions/ directory typically has the "sticky" bit set on it -
code :
drwx-wx-wt 2 root root 4096 Oct 15 11:21 /var/lib/php/sessions/

Subquery using JSON_TABLE gives ORA-0600 error

By : user3128845
Date : March 29 2020, 07:55 AM
this will help This is very likely an Oracle bug; ORA-00600 usually denotes an unhandled exception in the internal code written by the Oracle developers (not a bug caused by the "user", in this case you). Your best bet is to talk to Oracle Support (if you are a paying customer; I am not, for example). They may recognize the bug quickly, and tell you which patch to apply, assuming there is one already. Otherwise they will have to work on it.
In the meantime, you can move the subquery to a WITH clause. It will not work there either, but you can use the (undocumented?) hint MATERIALIZE, like so:
code :
  list (id) as 
       ( select /*+ materialize */ id                -- notice the hint here!
         from   json_table('[1244, 1188]', '$[*]' columns(id number path '$')))
select *
from   your_table
where  id in (select id from list)
Related Posts Related Posts :
  • Can someone explain to me why my factorial recursion code can't be compiled
  • Make same #define in every file
  • String to ASCII Hex splitting in C
  • Non-negative integer?
  • Issues with regular expression rejecting string
  • C program incrementing variable with for loop
  • How to prevent LD_PRELOAD on a binary?
  • Why printf doesn't print directly a variable in C?
  • What does it mean that condition?
  • What is the difference between int (*cmp)(void) and int *cmp(void)?
  • What is the wrong in the following c code ? MISRA quality warning message
  • Problem with finding mistake in program with using valgrind
  • Creating C functions with arguments but no returns, what went wrong?
  • Function of retval in pthread_join
  • I am getting a warning saying I have reached end of non-void function
  • Why does GCC only complain about an unsigned int argument being used with %i when -pedantic is given?
  • How random function really works in C?
  • Linux: warning implicit declaration of function of system call
  • Good STL-like library for C
  • Why am I getting a double free or corruption error with realloc()?
  • GTK implementation of MessageBox
  • shadow
    Privacy Policy - Terms - Contact Us © voile276.org